48 #include "RiTypesHelper.h"
97 #define k_RixShadingVersion 240 // XXY (XX: MAJOR, Y:MINOR)
190 virtual int Init(
RixContext& ctx, RtUString
const pluginPath) = 0;
307 PIXAR_ARGUSED(rixCtx);
308 PIXAR_ARGUSED(handle);
309 PIXAR_ARGUSED(parameterList);
310 PIXAR_ARGUSED(instanceData);
328 uint32_t
const editHints,
331 PIXAR_ARGUSED(rixCtx);
332 PIXAR_ARGUSED(handle);
333 PIXAR_ARGUSED(instanceParams);
334 PIXAR_ARGUSED(editHints);
335 PIXAR_ARGUSED(instanceData);
382 typeSize =
sizeof(int);
385 typeSize =
sizeof(float);
388 typeSize =
sizeof(RtFloat2);
391 typeSize =
sizeof(RtFloat3);
394 typeSize =
sizeof(RtColorRGB);
397 typeSize =
sizeof(RtPoint3);
400 typeSize =
sizeof(RtVector3);
403 typeSize =
sizeof(RtNormal3);
406 typeSize =
sizeof(RtMatrix4x4);
409 typeSize =
sizeof(RtUString);
415 typeSize =
sizeof(
void*);
587 virtual int GetParamId(
const RtUString name,
int* paramId)
const = 0;
592 virtual int GetParamId(
int plistIndex,
int* paramId)
const = 0;
600 int* arrayLength = NULL)
const = 0;
607 int err =
GetParamInfo(paramId, type, &cInfo, arrayLength);
629 void const** instance)
const = 0;
631 void const** instance)
const = 0;
633 void const** instance)
const = 0;
840 void* instanceData)
const = 0;
1036 float const** radius = NULL)
const = 0;
1039 float const** radius = NULL)
const = 0;
1042 float const** radius = NULL)
const = 0;
1047 RtMatrix4x4
const** var)
const = 0;
1056 float const** dXdv)
const = 0;
1059 float const** dYdu,
float const** dXdv,
1060 float const** dYdv)
const = 0;
1063 float const** dYdu,
float const** dZdu,
float const** dXdv,
1064 float const** dYdv,
float const** dZdv)
const = 0;
1127 const RtUString toSpace, RtFloat3* var,
float* radius = NULL)
const = 0;
1135 virtual int GetTransform(
const RtUString fromSpace,
const RtUString toSpace,
1136 RtMatrix4x4
const** matrix,
int* numMatrices)
const = 0;
1199 int const* dflt = NULL,
bool promoteToVarying =
false)
const = 0;
1202 float const* dflt = NULL,
1203 bool promoteToVarying =
false)
const = 0;
1206 RtColorRGB
const* dflt = NULL,
1207 bool promoteToVarying =
false)
const = 0;
1210 RtFloat3
const* dflt = NULL,
1211 bool promoteToVarying =
false)
const = 0;
1214 RtMatrix4x4
const* dflt = NULL,
1215 bool promoteToVarying =
false)
const = 0;
1218 RtUString
const* dflt = NULL,
1219 bool promoteToVarying =
false)
const = 0;
1223 bool promoteToVarying =
false)
const = 0;
1241 T
const* constResult;
1247 memcpy(*result, constResult, this->
numPts *
sizeof(T));
1250 if (promoteToVarying)
1253 std::fill_n(*result, this->
numPts, constResult[0]);
1257 *result = (T*)
Allocate(1,
sizeof(T), mcat);
1258 (*result)[0] = constResult[0];
1273 virtual int GetParamId(
const RtUString name,
int* paramId)
const = 0;
1281 int* arrayLength = NULL)
const = 0;
1288 int err =
GetParamInfo(paramId, type, &cInfo, arrayLength);
1319 const RtUString subset = US_NULL,
1320 const RtUString excludeSubset = US_NULL,
1328 virtual bool GetLightEmission(RtColorRGB* emission,
int* lightGroupIds = NULL)
const = 0;
1350 T* mem =
static_cast<T*
>(
Allocate(nObjs,
sizeof(T), cat));
1351 return new (mem) T[nObjs];
1370 template <
typename T>
1373 if (num == 0)
return NULL;
1376 template <
typename T>
1379 if (num == 0)
return NULL;
1380 return (T*)m_sCtx->
Allocate(num,
sizeof(T), memcat);
1382 template <
typename T>
1387 if (num == 0)
return NULL;
1390 template <
typename T>
1393 if (num == 0)
return NULL;
1396 template <
typename T>
1399 if (num == 0)
return NULL;
1421 int const* membership = NULL)
const = 0;