|
Hi,
I want to extract some of a model information over it’s animation. I know I have to use shape keys for it. For now, I have this :
XSI::CGeometryAccessor ga = mesh.GetGeometryAccessor( XSI::siConstructionModeModeling, XSI::siCatmullClark, 0 )
XSI::CRefArray refShapeKeys = ga.GetShapeKeys()
LONG nShapeKeys = refShapeKeys.GetCount()
XSI::ShapeKey currentKey = refShapeKeys[0]; XSI::ShapeKey frame0 = currentKey.EvaluateAt(0)
XSI::CClusterPropertyElementArray frameElem = frame0.GetElements()
LONG frameElemValueSize = frameElem.GetValueSize()
LONG frameElemCount = frameElem.GetCount()
So, first of all, the EvaluateAt method… will it return me the something at a particular frame?
Second of all, the frameElemValueSize gives me 78 right now and frameElemCount, 21670. How can I know what are the frame elements (vertices, polygons...) and each of the values
for each element (UVs, position, color....)?? When I call EvaluateAt, information in this array will change too?
Any help will be appreciated!
Thanks!
|
|
|
|
Well, I found my error. I need to call EvaluateAt on the primitive itself then, the GeometryAccessor is updated to the frame I want.
|
|
|