HDK
|
Procedural to render a single GT primitive. More...
#include <RAY_ProcGT.h>
Classes | |
class | StylingContext |
Public Types | |
using | StylerInfoArray = StylingContext::StylerInfoArray |
using | SharedPrimGroup = StylingContext::SharedPrimGroup |
using | GroupSharingMap = StylingContext::GroupSharingMap |
Static Public Member Functions | |
static const GT_RefineParms * | mantraRefineParms (const RAY_Procedural &proc) |
![]() | |
static void | optimizeGeometry (GU_Detail &gdp, bool create_normals_if_needed) |
static void | optimizeGeometry (GU_DetailHandle &gdp, bool create_normals_if_needed) |
void | setInstanceTransform (const RAY_ProceduralChildPtr &kid, const GT_TransformHandle &xform) const |
void | processInstanceAttributes (const RAY_ProceduralChildPtr &kid, const GT_AttributeListHandle &attrib, exint idx) const |
void | velocityBlurTransform (const RAY_ProceduralChildPtr &kid, const GT_TransformArrayHandle &xforms, const GT_DataArrayHandle &v, const GT_DataArrayHandle &w, const GT_DataArrayHandle &accel, const GT_DataArrayHandle &pivot, const GT_TransformHandle &packed, exint xform) const |
void | renderPrim (const GT_PrimitiveHandle &prim, StylingContext &styling) const |
Procedural to render a single GT primitive.
When rendering GT primitives, they will be refined until they hit geometry that Mantra can handle.
When GT_PRIM_INSTANCE primitives are encountered, the procedural will create multiple instance objects in mantra, allowing the geometry to be shared between instances automatically. In addition, the following uniform/detail attributes are handled on the instance primitives:
shop_materialpath
is found, then additional attributes (material_override
and property_override
) are evaluated to handle shader argument and property overrides.lightcategories
Set the lightcategories property on the instance
Definition at line 48 of file RAY_ProcGT.h.
Definition at line 73 of file RAY_ProcGT.h.
Definition at line 72 of file RAY_ProcGT.h.
Definition at line 71 of file RAY_ProcGT.h.
RAY_ProcGT::RAY_ProcGT | ( | const GT_PrimitiveHandle & | prim, |
bool | use_multi_segments = true , |
||
fpreal | shutter_close = -1 |
||
) |
A mantra procedural to render a GT primitive. If the GT primitive has multiple segments, the primitive will be rendered with deformation motion blur unless use_multi_segments
is false.
When multi-segment blur is active, the shutter_close
can be specified. If the shutter_close
is less than 0, the value will be imported from the camera:shutter setting. If shutter_close
is 0, multi-segment blur will be disabled.
If the GT primitive has the proper sub-frame sampling time, then you likely want to set the shutter_close
to 1.0.
RAY_ProcGT::RAY_ProcGT | ( | const UT_Array< GT_PrimitiveHandle > & | primitives, |
fpreal | shutter_close = -1 |
||
) |
Alternatively, motion segments can be specified using an array of primitives.
|
override |
|
overridevirtual |
Methods from RAY_Procedural
Reimplemented from RAY_Procedural.
|
overridevirtual |
Methods from RAY_Procedural
Implements RAY_Procedural.
void RAY_ProcGT::dump | ( | bool | dump_full_geo = false | ) |
|
overridevirtual |
Methods from RAY_Procedural
Implements RAY_Procedural.
|
overridevirtual |
Methods from RAY_Procedural
Implements RAY_Procedural.
void RAY_ProcGT::instanceVelocityBlur | ( | const GT_DataArrayHandle & | v, |
const GT_DataArrayHandle & | w, | ||
const GT_DataArrayHandle & | a, | ||
const GT_DataArrayHandle & | pivot | ||
) |
|
static |
void RAY_ProcGT::processInstanceAttributes | ( | const RAY_ProceduralChildPtr & | kid, |
const GT_AttributeListHandle & | attrib, | ||
exint | idx | ||
) | const |
Create a new styler for each instance in a child ProcGT based on our existing instance stylers and any new instance defined in the prim.
|
overridevirtual |
Methods from RAY_Procedural
Implements RAY_Procedural.
void RAY_ProcGT::renderPrim | ( | const GT_PrimitiveHandle & | prim, |
StylingContext & | styling | ||
) | const |
Create a new styler for each instance in a child ProcGT based on our existing instance stylers and any new instance defined in the prim.
void RAY_ProcGT::setInstanceTransform | ( | const RAY_ProceduralChildPtr & | kid, |
const GT_TransformHandle & | xform | ||
) | const |
Create a new styler for each instance in a child ProcGT based on our existing instance stylers and any new instance defined in the prim.
|
inline |
Definition at line 143 of file RAY_ProcGT.h.
|
inline |
Definition at line 116 of file RAY_ProcGT.h.
void RAY_ProcGT::velocityBlurTransform | ( | const RAY_ProceduralChildPtr & | kid, |
const GT_TransformArrayHandle & | xforms, | ||
const GT_DataArrayHandle & | v, | ||
const GT_DataArrayHandle & | w, | ||
const GT_DataArrayHandle & | accel, | ||
const GT_DataArrayHandle & | pivot, | ||
const GT_TransformHandle & | packed, | ||
exint | xform | ||
) | const |
Create a new styler for each instance in a child ProcGT based on our existing instance stylers and any new instance defined in the prim.