OpenShadingLanguage: Compatibility with version 1.14 (beta)
Pull Request: https://projects.blender.org/blender/blender/pulls/132654
This commit is contained in:
@@ -10,7 +10,11 @@ CCL_NAMESPACE_BEGIN
|
||||
|
||||
#if OSL_LIBRARY_VERSION_CODE >= 11302
|
||||
using OSLUStringHash = OSL::ustringhash;
|
||||
# if OSL_LIBRARY_VERSION_CODE >= 11400
|
||||
using OSLUStringRep = OSL::ustringhash;
|
||||
# else
|
||||
using OSLUStringRep = OSL::ustringrep;
|
||||
# endif
|
||||
|
||||
static inline OSL::ustring to_ustring(OSLUStringHash h)
|
||||
{
|
||||
|
||||
@@ -1640,7 +1640,11 @@ int OSLRenderServices::pointcloud_search(OSL::ShaderGlobals *sg,
|
||||
const float radius,
|
||||
const int max_points,
|
||||
bool sort,
|
||||
#if OSL_LIBRARY_VERSION_CODE >= 11400
|
||||
int *indices,
|
||||
#else
|
||||
size_t *out_indices,
|
||||
#endif
|
||||
float *out_distances,
|
||||
const int derivs_offset)
|
||||
{
|
||||
@@ -1649,7 +1653,11 @@ int OSLRenderServices::pointcloud_search(OSL::ShaderGlobals *sg,
|
||||
|
||||
int OSLRenderServices::pointcloud_get(OSL::ShaderGlobals *sg,
|
||||
OSLUStringHash filename,
|
||||
#if OSL_LIBRARY_VERSION_CODE >= 11400
|
||||
const int *indices,
|
||||
#else
|
||||
size_t *indices,
|
||||
#endif
|
||||
const int count,
|
||||
OSLUStringHash attr_name,
|
||||
const TypeDesc attr_type,
|
||||
|
||||
@@ -142,13 +142,22 @@ class OSLRenderServices : public OSL::RendererServices {
|
||||
const float radius,
|
||||
const int max_points,
|
||||
bool sort,
|
||||
#if OSL_LIBRARY_VERSION_CODE >= 11400
|
||||
int *out_indices,
|
||||
#else
|
||||
size_t *out_indices,
|
||||
#endif
|
||||
float *out_distances,
|
||||
int derivs_offset) override;
|
||||
|
||||
int pointcloud_get(OSL::ShaderGlobals *sg,
|
||||
OSLUStringHash filename,
|
||||
#if OSL_LIBRARY_VERSION_CODE >= 11400
|
||||
const int *indices,
|
||||
#else
|
||||
size_t *indices,
|
||||
#endif
|
||||
|
||||
const int count,
|
||||
OSLUStringHash attr_name,
|
||||
const TypeDesc attr_type,
|
||||
|
||||
Reference in New Issue
Block a user