I3dExSkinable Struct Reference
[External Interfaces]

Inheritance diagram for I3dExSkinable:

IMCUnknown List of all members.

Public Member Functions

virtual void MCCOMAPI AttachSkeleton (TMCPtrArray< I3DShJoint > &joints, I3DShInstance *instance, boolean computeWeights=true, boolean computeJointsTransforms=true)=0
virtual void MCCOMAPI DettachAllJoints ()=0
virtual boolean MCCOMAPI IsAttached ()=0
virtual void MCCOMAPI GetJoints (TMCPtrArray< I3DShJoint > &joints)=0
virtual void MCCOMAPI GetJointsInverseReferenceTransforms (TMCArray< TTransform3D > &outTransforms)=0
virtual void MCCOMAPI SetJointsInverseReferenceTransforms (const TMCArray< TTransform3D > &inTransforms)=0
virtual void MCCOMAPI InvalidateSkining ()=0
virtual void MCCOMAPI GetInstance (I3DShInstance **instance)=0
virtual void MCCOMAPI GetInstanceGlobalReferenceTransform (TTransform3D &outTransform)=0
virtual void MCCOMAPI SetInstanceGlobalReferenceTransform (const TTransform3D &inTransform)=0

Detailed Description

I3DExSkinable is an interface for a primitive that accepts bones. To create a primitive to which bones can be applied, you just need to derive it from this interface and implement its methods.

At this point only the vertex primitives support this interface.

If you implement the I3DExSkinable interface, it is recommended that your class offers a way to access weights data. For example, you can use the I3DExVertex interface to access the weights on a vertex of a vertex primitive (using SetSkiningData, GetSkiningData).

The classes supporting I3dExSkinable should provide a low level api to access the skining data. For example, with I3DExVertexPrimitive you can get an I3DExVertex interface for each vertex and then manipulate the joints weights with SetSkiningData and GetSkiningData.


Member Function Documentation

virtual void MCCOMAPI I3dExSkinable::AttachSkeleton (  TMCPtrArray< I3DShJoint > &  joints,
I3DShInstance *  instance,
boolean  computeWeights = true,
boolean  computeJointsTransforms = true
)  [pure virtual]
 

Attaches the given skeletton, this object and its single instance together for skinning Note: do NOT call it twice without first dettaching the Skeleton

Parameters:
joints The list of the joints forming the skeleton of the the primitive to. They MUST have a common root.
computeWeights If true, automatically computes the weights of the joints for each vertex. (pass false only when the weights are already there, eg when loading a file)
computeJointsTransforms: If true, stores the inverse of the global transform of each joint if you pass false, you must call SetJointsInverseReferenceTransforms.
instance The single instance of the object

virtual void MCCOMAPI I3dExSkinable::DettachAllJoints (   )  [pure virtual]
 

Turns back to a non skinned object

virtual void MCCOMAPI I3dExSkinable::GetInstance (  I3DShInstance **  instance  )  [pure virtual]
 

Returns THE skinned instance.

Parameters:
instance A pointer to this instance that is returned.

virtual void MCCOMAPI I3dExSkinable::GetInstanceGlobalReferenceTransform (  TTransform3D &  outTransform  )  [pure virtual]
 

Returns the global transform of the instance (when the skining was created).

virtual void MCCOMAPI I3dExSkinable::GetJoints (  TMCPtrArray< I3DShJoint > &  joints  )  [pure virtual]
 

Returns the joints attached to the vertex object

Parameters:
joints Returns the list of the joints that are used for the skinning of this primitive.

virtual void MCCOMAPI I3dExSkinable::GetJointsInverseReferenceTransforms (  TMCArray< TTransform3D > &  outTransforms  )  [pure virtual]
 

Returns the inverse global transforms that the joints had when they were attached to the object The array has the same order and number of elements than GetJoints

Parameters:
outTransforms The array of the original inverse transform of the joints.

virtual void MCCOMAPI I3dExSkinable::InvalidateSkining (   )  [pure virtual]
 

Called when the transform of a joint change so that the skinnable can invalidate its caches.

virtual boolean MCCOMAPI I3dExSkinable::IsAttached (   )  [pure virtual]
 

Returns true if the vertex primitive is skinned

virtual void MCCOMAPI I3dExSkinable::SetInstanceGlobalReferenceTransform (  const TTransform3D &  inTransform  )  [pure virtual]
 

Sets the global transform of the instance (when loading a file).

virtual void MCCOMAPI I3dExSkinable::SetJointsInverseReferenceTransforms (  const TMCArray< TTransform3D > &  inTransforms  )  [pure virtual]
 

Sets the inverse global transforms that the joints had when they were attached to the object The array must have the same order and number of elements than the one given to AttachSkeleton

Parameters:
inTransforms The array of the original inverse transform of the joints.


The documentation for this struct was generated from the following file:
Generated on Mon Mar 14 12:29:01 2005 for Carrara SDK Doc by  doxygen 1.3.9.1