[ < ] | [ > ] | [ << ] | [ Up ] | [ >> ] | [Top] | [Contents] | [Index] | [ ? ] |
Written by Jorrit Tyberghein, jorrit.tyberghein@uz.kuleuven.ac.be.
A 3D Sprite is a complex set of 3D triangles that either supports frame based animation or else skeletal animation.
The following SCF class names are used (for CS_LOAD_PLUGIN()
):
Objects in this plugin implement the following SCF interfaces (get
with SCF_QUERY_INTERFACE()
):
Use the `iSprite3DFactoryState' SCF interface to access settings for a 3D sprite factory. The definition of this interface can be found in `CS/include/imesh/sprite3d.h' and that is also the include file you need to include in your applications to use this plugin. Using this interface you can access the material, triangles, vertices, texture coordinates, normals, frames, actions, skeletal structure, and various other configuration parameters for a 3D sprite factory.
For frame based animation you need to access the `iSpriteFrame' and `iSpriteAction' interfaces (defined in `CS/include/imesh/sprite3d.h') and for skeletal animation you need to work with `iSkeletonLimb', `iSkeletonConnection', and `iSkeleton' (defined in `CS/include/imesh/skeleton.h'). Note that you will also have to setup one frame if you use skeletal animation. This frame defines the default setup of the sprite if the skeleton is at rest (i.e. all transformations in the skeleton connectors are identity transformations).
<material>materialname</material>
<frame name="framename"><v x="" y="" z="" u="" v="" /> ...
<action name="actionname"><f name="framename"><delay>
<skeleton name="skeletonname"> ...
<t v1="" v2="" v3="" />
<smooth>base/frame</smooth>
<tween>yes/no</tween>
A skeleton is a hierarchical structure which is defined as follows:
<limb name="limbname"> ...
vertices <v v1="" ... />
<transform> ...
`iSprite3DState' is the SCF interface that you can use to set/get settings for a 3D Sprite object. The definition of this interface can be found in `CS/include/imesh/sprite3d.h' and that's also the include file you need to include in your applications to use this plugin. Using this interface you can access the material, blending mode (mixmode), current frame and action, current skeletal animation state, and various other configuration parameters for a 3D sprite object.
The state of a skeleton is described via the following interfaces which are defined in `CS/include/imesh/sprite3d.h':
iSkeletonLimbState
,
iSkeletonConnectionState
iSkeletonState
<factory>factoryname</factory>
<mixmode><mode \></mixmode>
<material>materialname</material>
<tween>yes/no</tween>
<lighting>yes/no</lighting>
<basecolor red="" green="" blue="" />
<action name="actionname">
The `sprite3d' plugin supports the following configuration parameters via the `iConfig' interface in the mesh object type plugin:
sprlod
sprlq
[ < ] | [ > ] | [ << ] | [ Up ] | [ >> ] | [Top] | [Contents] | [Index] | [ ? ] |