Rendercache¶
ILxRenderCacheService¶
-
class
ILxRenderCacheService
¶ Public Functions
-
LxResult
CreateRenderCache
(LXtObjectID self, void **ppvObj, unsigned int createFlags)¶ Create render cache. Caller can pass LXiRENDERCACHE_XXX flags to guide the cache initialization.
-
bool
NewRenderCache
(CLxLoc_RenderCache &rcache, unsigned createFlags)¶ User Class Only:
-
LxResult
LXfRENDERCACHE_GEOCACHE_DISPLACE
LXfRENDERCACHE_GEOCACHE_GENFUR
LXfRENDERCACHE_FULL
LXfRENDERCACHE_TRACK_CURRENT_SCENE
LXfRENDERCACHE_TURN_OFF_AUTO_UPDATES
LXfRENDERCACHE_FORCE_FULL_UPDATE
ILxRenderCache¶
-
class
ILxRenderCache
¶ Public Functions
-
void
Time
(LXtObjectID self, double *time, double *timeOffsets)¶ Return current render cache time and time offsets (for motion blur). Argument timeOffsets is an array of 2 double values.
-
LxResult
Update
(LXtObjectID self, double time, int force)¶ Update render cache to given time. If render cache is created without LXfRENDERCACHE_TURN_OFF_AUTO_UPDATES flag, the method will return LXe_FAILED. If time is the same as internal time no update will happen. In that case specify the force to force the full render cache update.
-
void
Clear
(LXtObjectID self)¶ Clear the render cache.
-
LxResult
GeoSurfaceCount
(LXtObjectID self, int *count)¶ Return number of geo cache surfaces.
-
LxResult
GeoSurfaceAt
(LXtObjectID self, int index, void **srf)¶ Get geo cache surface at given index.
-
bool
GetGeoSurface
(int index, CLxLoc_GeoCacheSurface &srf)¶ User Class Only:
-
void
ILxRenderCacheListener1¶
-
class
ILxRenderCacheListener1
¶ Public Functions
-
void
RenderCacheDestroy
(LXtObjectID self)¶
-
void
UpdateBegin
(LXtObjectID self)¶
-
void
UpdateEnd
(LXtObjectID self)¶
-
void
GeoCacheSurfaceAdd
(LXtObjectID self, LXtObjectID geoSrf)¶
-
void
GeoCacheSurfaceRemove
(LXtObjectID self, LXtObjectID geoSrf)¶
-
void
GeoCacheSurfaceGeoUpdate
(LXtObjectID self, LXtObjectID geoSrf)¶
-
void
GeoCacheSurfaceXformUpdate
(LXtObjectID self, LXtObjectID geoSrf)¶
-
void
GeoCacheSurfaceShaderUpdate
(LXtObjectID self, LXtObjectID geoSrf)¶
-
void
ILxRenderCacheListener¶
-
class
ILxRenderCacheListener
¶ Public Functions
-
void
RenderCacheDestroy
(LXtObjectID self)¶ Called when render cache is being destroyed. This happens when user changes the current scene (if LXfRENDERCACHE_TRACK_CURRENT_SCENE was specified).
-
void
UpdateBegin
(LXtObjectID self)¶
-
void
UpdateEnd
(LXtObjectID self)¶
-
void
GeoCacheSurfaceAdd
(LXtObjectID self, LXtObjectID geoSrf)¶ Called after the geo surface has been added to cache.
-
void
GeoCacheSurfaceRemove
(LXtObjectID self, LXtObjectID geoSrf)¶ Called before the geo surface has been removed from cache.
-
void
GeoCacheSurfaceGeoUpdate
(LXtObjectID self, LXtObjectID geoSrf)¶ Called when the geo surface data has been changed (this method is called only for non-instanced surfaces).
-
void
GeoCacheSurfaceXformUpdate
(LXtObjectID self, LXtObjectID geoSrf)¶ Called when the xform data has been changed.
-
void
GeoCacheSurfaceShaderUpdate
(LXtObjectID self, LXtObjectID geoSrf)¶ Called when the shading data has been changed.
-
void
RenderCacheClear
(LXtObjectID self)¶ Called when render cache is cleared.
-
void
ILxGeoCacheSegment¶
-
class
ILxGeoCacheSegment
¶ Public Functions
-
LxResult
GetBBox
(LXtObjectID self, LXtBBox *bbox)¶ Return the segment’s bounding box in the world-space.
-
void
PolygonCount
(LXtObjectID self, int *count)¶
-
void
VertexCount
(LXtObjectID self, int *count)¶
-
void
VertsPerPoly
(LXtObjectID self, int *count)¶ All polygons in the segments have same number of vertices in the polygon. It can be 3 for triangles, 2 for curves and (hair & fur) and 1 for particles.
-
void
VertexFeatureCount
(LXtObjectID self, int feature, int *count)¶ Return if the vertex feature is stored in the segment. OPOS and ONRM are always stored. The count for WVEL, RAD and FUR will be either 0 or 1. For UV, DPDU and DPDV the count will return how many UV vmaps are stored in the segment.
-
LxResult
GetPolygonVertexFeature
(LXtObjectID self, int feature, void *featureData, int count, int start)¶ Segment vertex feature is copied per-polygon-per-vertex into client’s memory (like a triangle soup). Caller can specify the start offset into the segment’s data. The start and count are in number of elements which are from 0 to VertsPerPoly * PolygonCount (not in byte size).
-
LxResult
GetVertexFeature
(LXtObjectID self, int feature, void *featureData, int count, int start)¶ Segment vertex feature is copied per-vertex into client’s memory. Caller can specify the start offset into the segment’s data. The start and count are in number of elements which are from 0 to VertexCount (not in byte size).
-
LxResult
GetPolygonVertexInds
(LXtObjectID self, int *polyVertexInds, int count, int start)¶ Copy polygon vertex indices into client’s memory. Caller can specify the start offset into the segment’s data. The start and count are in number of elements which are from 0 to VertsPerPoly * PolygonVertexCount (not in byte size).
-
LxResult
LXiRENDERCACHE_GEOVERT_OPOS
LXiRENDERCACHE_GEOVERT_ONRM
LXiRENDERCACHE_GEOVERT_OVEL
LXiRENDERCACHE_GEOVERT_RAD
LXiRENDERCACHE_GEOVERT_FUR
LXiRENDERCACHE_GEOVERT_UV
LXiRENDERCACHE_GEOVERT_DPDU
LXiRENDERCACHE_GEOVERT_DPDV
LXtGeoCacheSrfVisibility¶
-
struct
st_LXtGeoCacheSrfVisibility
¶ Surface visibility flags
ILxGeoCacheSurface¶
-
class
ILxGeoCacheSurface
¶ Public Functions
-
LxResult
ShaderMaskName
(LXtObjectID self, const char **name)¶ Obtain geo surface shader mask name (for example Surf(ShaderMaskName)).
-
int
ShaderMaskType
(LXtObjectID self)¶ Returns one of LXi_SURF_XXX flags.
-
LxResult
SourceItem
(LXtObjectID self, void **ppvObj)¶ Every surface has a source item. For replicated and instanced surfaces this method will return the source mesh.
-
int
IsInstanced
(LXtObjectID self)¶ Returns 1 if surface is instanced.
-
int
InstanceIndex
(LXtObjectID self)¶ Returns surface instance index, if surface is not instanced the returned value is -1.
-
LxResult
SourceSurface
(LXtObjectID self, void **ppvObj)¶ If geo surface is instanced then it doesn’t contain any geometry segments. This mehtod returns the source geo cache surface which contains the segment data.
-
LxResult
GetBBox
(LXtObjectID self, LXtBBox *bbox)¶ Obtain surface’s bounding box.
-
LxResult
GetXfrm
(LXtObjectID self, LXtVector pos, LXtMatrix rot, LXtVector scl, int endpoint)¶ Return surface’s xform information at given time endpoint (T0 or T1). T0 (=0) is time for shutter open, T1 (=1) is time for shutter close.
-
void
SegmentCount
(LXtObjectID self, int *count)¶ Return how many segments are in this surface.
-
void
PolygonCount
(LXtObjectID self, int *count)¶ Return how many polygons are in this surface.
-
void
VertexCount
(LXtObjectID self, int *count)¶ Return how many vertices are in this surface.
-
LxResult
SegmentAt
(LXtObjectID self, int index, void **segment)¶ Get segment by index
-
LxResult
VisibilityFlags
(LXtObjectID self, LXtGeoCacheSrfVisibility *flags)¶ Return surface visibility flags (visible in camera, etc.)
-
int
ID
(LXtObjectID self)¶ Return surface unique id.
-
int
IsValid
(LXtObjectID self)¶ Return if surface is valid, i.e. not deleted.
-
LxResult
LoadSegments
(LXtObjectID self)¶ Populate geometry segments with vertices and polygons. If surface is already populated this method will do nothing. Use this method when you want to populate geometry cache on-demand.
-
LxResult
UnloadSegments
(LXtObjectID self)¶
-
ILxTableauVertexID
GetVertexDesc
(LXtObjectID self)¶ Return ILxTableauVertexID which can be used to query vertex information.
-
const char *
MaterialPTag
(LXtObjectID self)¶
-
const char *
PartPTag
(LXtObjectID self)¶
-
const char *
PickPTag
(LXtObjectID self)¶
-
LxResult
ShaderLayerCount
(LXtObjectID self, unsigned int *count)¶ Return the number of shader tree layers applicable to this surface.
-
LxResult
ShaderLayerAt
(LXtObjectID self, unsigned int index, void **shaderLayer)¶ Extract the shader tree layer item at the specified index.
-
bool
GetSourceItem
(CLxLoc_Item &item)¶ User Class Only:
-
bool
GetSourceSurface
(CLxLoc_GeoCacheSurface &srf)¶ User Class Only:
-
bool
GetSegment
(int index, CLxLoc_GeoCacheSegment &seg)¶ User Class Only:
-
bool
GetShaderLayer
(unsigned int index, CLxLoc_Item &item)¶ User Class Only:
-
LxResult