10 #ifndef GT_PrimAgentShape_h
11 #define GT_PrimAgentShape_h
55 exint getNumMatGroups()
const;
56 exint getMatGroupNumInstances(
exint grp_idx)
const;
57 int getMatGroupMaterialID(
exint grp_idx)
const;
63 int getNumTransformsPerInstance()
const;
64 int getNumBlendWeightsPerInstance()
const;
67 int getNumPoints()
const;
70 bool hasBlendShapeNormalOffsets()
const;
76 bool packed_xform_only)
const;
79 void fetchMatGroupTransforms(
int idx,
81 bool packed_xform_only)
const;
85 void fetchMatGroupRigTransforms(
int idx,
fpreal32 *
buf)
const;
89 void fetchMatGroupBlendWeights(
91 std::pair<int32, fpreal32> *active_targets)
const;
94 void fetchMatGroupColors(
int idx,
uint8 *
buf)
const;
101 int getVisibleInstances(
int grp_idx,
104 fpreal lod_bias = 1.0)
const;
110 void addShapeInstance(
int xform_index,
119 {
return "GT_PrimAgentShape"; }
123 int nsegments)
const override
124 { doEnlargeBounds(boxes, nsegments,
false); }
126 int nsegments)
const override
127 { doEnlargeBounds(boxes, nsegments,
true); }
153 int getNumUnstyledGroups()
const;
154 ShapeInstance &getShapeInstancesForUnstyledGroup(
int mat_group);
155 void resetStyledMatGroups();
168 bool myUseStyledMatGroups;
182 {
return myGeometry; }
187 return myUseStyledMatGroups ? myStyledMatGroup.entries()
188 : myMatGroup.entries();
194 const ShapeInstance &inst = myUseStyledMatGroups ? *myStyledMatGroup(i)
202 const ShapeInstance &inst = myUseStyledMatGroups ? *myStyledMatGroup(i)
210 const ShapeInstance &inst = myUseStyledMatGroups ? *myStyledMatGroup(i)
218 const ShapeInstance &inst = myUseStyledMatGroups ? *myStyledMatGroup(i)
226 return myMatGroup.entries();
232 return myMatGroup(mat_group);
238 for(
auto grp : myStyledMatGroup)
240 myStyledMatGroup.entries(0);
241 myUseStyledMatGroups =
false;
247 myUseStyledMatGroups =
true;
249 myStyledMatGroup.last()->myMaterialID = mat_id;
250 return myStyledMatGroup.last();
259 {
return myLODLevel; }
263 {
return myLODGroup; }
GLenum GLuint GLenum GLsizei const GLchar * buf
virtual bool refine(GT_Refine &refiner, const GT_RefineParms *parms=NULL) const
GT_DataArrayHandle getMatRemapAttrib() const
virtual bool getTopologyVersion(int64 &version) const
Returns the topology version for the primitive.
ShapeInstance & getShapeInstancesForUnstyledGroup(int mat_group)
int getNumUnstyledGroups() const
GT_PrimitiveHandle doSoftCopy() const override
ShapeInstance * addStyledMatGroup(int mat_id)
int getMatGroupMaterialID(exint grp_idx) const
UT_Array< GT_AgentShapeBindingID > myBindings
IFDmantra you can see code vm_image_mplay_direction endcode When SOHO starts a render
const UT_IntArray & getMatGroupAgentPointIDs(exint grp_idx) const
int getMotionSegments() const override
Abstract data class for an array of float, int or string data.
virtual GT_PrimitiveHandle doSoftCopy() const =0
const char * className() const override
void resetStyledMatGroups()
void enlargeBounds(UT_BoundingBox boxes[], int nsegments) const override
int lodLevel() const
Which LOD level this shape represents: 0=primary, 1+ lower resolutions.
GA_Size GA_Index
Define the strictness of GA_Offset/GA_Index.
The base class for all GT primitive types.
GU_ConstDetailHandle & detail() const
virtual int64 getMemoryUsage() const =0
exint getNumMatGroups() const
one set of transforms per material.
GT_API const UT_StringHolder version
Processes primitives generated by refinement process.
exint entries() const
Alias of size(). size() is preferred.
void enlargeRenderBounds(UT_BoundingBox boxes[], int nsegments) const override
const GT_ShapeLODGroupHandle & shapeGroup() const
Access to the shared data between LOD levels of the same agent shape.
const GT_PrimitiveHandle & geometry() const
shape geometry.
A shape belonging to agents, instanced with material assignments.
const UT_IntArray & getMatGroupAgentPrimIDs(exint grp_idx) const
int getPrimitiveType() const override
Index of a shape binding in one of the agent's current layers.
GT_PrimitiveHandle doHarden() const override
exint getMatGroupNumInstances(exint grp_idx) const