- Cal3D 0.9 API Reference - |
#include <coremodel.h>
Public Member Functions | |
CalCoreModel () | |
Constructs the core model instance. | |
virtual | ~CalCoreModel () |
Destructs the core model instance. | |
bool | create (const std::string &strName) |
Creates the core model instance. | |
void | destroy () |
Destroys the core model instance. | |
Cal::UserData | getUserData () |
Provides access to the user data. | |
void | setUserData (Cal::UserData userData) |
Stores user data. | |
void | scale (float factor) |
Scale the core model. | |
int | addCoreAnimation (CalCoreAnimation *pCoreAnimation) |
Adds a core animation. | |
CalCoreAnimation * | getCoreAnimation (int coreAnimationId) |
Provides access to a core animation. | |
int | getCoreAnimationCount () |
Returns the number of core animations. | |
int | loadCoreAnimation (const std::string &strFilename) |
Loads a core animation. | |
int | loadCoreAnimation (const std::string &strFilename, const std::string &strAnimationName) |
Loads a core animation and bind it to a name. | |
int | unloadCoreAnimation (const std::string &name) |
Delete the resources used by the named core animation. | |
int | unloadCoreAnimation (int coreAnimationId) |
Delete the resources used by a core animation. | |
bool | saveCoreAnimation (const std::string &strFilename, int coreAnimationId) |
Saves a core animation. | |
bool | addAnimationName (const std::string &strAnimationName, int coreAnimationId) |
Creates or overwrites a string-to-animation ID mapping. | |
int | getCoreAnimationId (const std::string &strAnimationName) |
Retrieves the ID of the animation referenced by a string. | |
int | addCoreMorphAnimation (CalCoreMorphAnimation *pCoreMorphAnimation) |
Adds a core morph animation. | |
CalCoreMorphAnimation * | getCoreMorphAnimation (int coreMorphAnimationId) |
Provides access to a core morph animation. | |
int | getCoreMorphAnimationCount () |
Returns the number of core morph animations. | |
int | addCoreMaterial (CalCoreMaterial *pCoreMaterial) |
Adds a core material. | |
bool | createCoreMaterialThread (int coreMaterialThreadId) |
Creates a core material thread. | |
CalCoreMaterial * | getCoreMaterial (int coreMaterialId) |
Provides access to a core material. | |
int | getCoreMaterialCount () |
Returns the number of core materials. | |
int | getCoreMaterialId (int coreMaterialThreadId, int coreMaterialSetId) |
Returns a specified core material ID. | |
int | loadCoreMaterial (const std::string &strFilename) |
Loads a core material. | |
int | loadCoreMaterial (const std::string &strFilename, const std::string &strMaterialName) |
Loads a core material and bind it to a name. | |
int | unloadCoreMaterial (const std::string &name) |
Delete the resources used by the named core material. | |
int | unloadCoreMaterial (int coreMaterialId) |
Delete the resources used by a core material. | |
bool | saveCoreMaterial (const std::string &strFilename, int coreMaterialId) |
Saves a core material. | |
bool | setCoreMaterialId (int coreMaterialThreadId, int coreMaterialSetId, int coreMaterialId) |
Sets a core material ID. | |
bool | addMaterialName (const std::string &strMaterialName, int coreMaterialId) |
Creates or overwrites a string-to-core-material ID mapping. | |
int | getCoreMaterialId (const std::string &strMaterialName) |
Retrieves the ID of the core material referenced by a string. | |
int | addCoreMesh (CalCoreMesh *pCoreMesh) |
Adds a core mesh. | |
CalCoreMesh * | getCoreMesh (int coreMeshId) |
Provides access to a core mesh. | |
int | getCoreMeshCount () |
Returns the number of core meshes. | |
int | loadCoreMesh (const std::string &strFilename) |
Loads a core mesh. | |
int | loadCoreMesh (const std::string &strFilename, const std::string &strMeshName) |
Loads a core mesh and bind it to a name. | |
int | unloadCoreMesh (const std::string &name) |
Delete the resources used by the named core mesh. | |
int | unloadCoreMesh (int coreMeshId) |
Delete the resources used by a core mesh. | |
bool | saveCoreMesh (const std::string &strFilename, int coreMeshId) |
Saves a core mesh. | |
bool | addMeshName (const std::string &strMeshName, int coreMeshId) |
Creates or overwrites a string-to-core-mesh ID mapping. | |
int | getCoreMeshId (const std::string &strMeshName) |
Retrieves the ID of the core mesh referenced by a string. | |
CalCoreSkeleton * | getCoreSkeleton () |
Provides access to the core skeleton. | |
bool | loadCoreSkeleton (const std::string &strFilename) |
Loads the core skeleton. | |
bool | saveCoreSkeleton (const std::string &strFilename) |
Saves the core skeleton. | |
void | setCoreSkeleton (CalCoreSkeleton *pCoreSkeleton) |
Sets the core skeleton. | |
void | addBoneName (const std::string &strBoneName, int boneId) |
Creates or overwrites a string-to-boneId mapping. | |
int | getBoneId (const std::string &strBoneName) |
Retrieves the ID of the bone referenced by a string. |
|
Constructs the core model instance. This function is the default constructor of the core model instance. |
|
Destructs the core model instance. This function is the destructor of the core model instance. |
|
Creates or overwrites a string-to-animation ID mapping. This function makes an animation ID reference-able by a string name. Note that we don't verify that the ID is valid because the animation may be added later. Also, if there is already a helper with this name, it will be overwritten without warning.
|
|
Creates or overwrites a string-to-boneId mapping. This function makes a bone ID reference-able by a string name.
|
|
Adds a core animation. This function adds a core animation to the core model instance.
|
|
Adds a core material. This function adds a core material to the core model instance.
|
|
Adds a core mesh. This function adds a core mesh to the core model instance.
|
|
Adds a core morph animation. This function adds a core morph animation to the core model instance.
|
|
Creates or overwrites a string-to-core-material ID mapping. This function makes a core material ID reference-able by a string name. Note that we don't verify that the ID is valid because the material may be added later. Also, if there is already a helper with this name, it will be overwritten without warning.
|
|
Creates or overwrites a string-to-core-mesh ID mapping. This function makes a core mesh ID reference-able by a string name. Note that we don't verify that the ID is valid because the mesh may be added later. Also, if there is already a helper with this name, it will be overwritten without warning.
|
|
Creates the core model instance. This function creates the core model instance.
|
|
Creates a core material thread. This function creates a new core material thread with the given ID.
|
|
Destroys the core model instance. This function destroys all data stored in the core model instance and frees all allocated memory. |
|
Retrieves the ID of the bone referenced by a string. This function returns a bone ID
|
|
Provides access to a core animation. This function returns the core animation with the given ID.
|
|
Returns the number of core animations. This function returns the number of core animations in the core model instance.
|
|
Retrieves the ID of the animation referenced by a string. This function returns an animation ID
|
|
Provides access to a core material. This function returns the core material with the given ID.
|
|
Returns the number of core materials. This function returns the number of core materials in the core model instance.
|
|
Retrieves the ID of the core material referenced by a string. This function returns a core material ID
|
|
Returns a specified core material ID. This function returns the core material ID for a specified core material thread / core material set pair.
|
|
Provides access to a core mesh. This function returns the core mesh with the given ID.
|
|
Returns the number of core meshes. This function returns the number of core meshes in the core model instance.
|
|
Retrieves the ID of the core mesh referenced by a string. This function returns a core mesh ID
|
|
Provides access to a core morph animation. This function returns the core morph animation with the given ID.
|
|
Returns the number of core morph animations. This function returns the number of core morph animations in the core model instance.
|
|
Provides access to the core skeleton. This function returns the core skeleton.
|
|
Provides access to the user data. This function returns the user data stored in the core model instance.
|
|
Loads a core animation and bind it to a name. This function loads a core animation from a file. It is equivalent to calling addAnimName(strAnimationName, loadCoreAnimation(strFilename)). If strAnimationName is already associated to a coreAnimationId because of a previous call to addAnimName, the same coreAnimationId will be used.
|
|
Loads a core animation. This function loads a core animation from a file.
|
|
Loads a core material and bind it to a name. This function loads a core material from a file. It is equivalent to calling addMaterialName(strMaterialName, loadCoreMaterial(strFilename)). If strMaterialName is already associated to a coreMaterialId because of a previous call to addMaterialName, the same coreMaterialId will be used.
|
|
Loads a core material. This function loads a core material from a file.
|
|
Loads a core mesh and bind it to a name. This function loads a core mesh from a file. It is equivalent to calling addMeshName(strMeshName, loadCoreMesh(strFilename)). If strMeshName is already associated to a coreMeshId because of a previous call to addMeshName, the same coreMeshId will be used.
|
|
Loads a core mesh. This function loads a core mesh from a file.
|
|
Loads the core skeleton. This function loads the core skeleton from a file.
|
|
Saves a core animation. This function saves a core animation to a file.
|
|
Saves a core material. This function saves a core material to a file.
|
|
Saves a core mesh. This function saves a core mesh to a file.
|
|
Saves the core skeleton. This function saves the core skeleton to a file.
|
|
Scale the core model. This function rescale all data that are in the core model instance
|
|
Sets a core material ID. This function sets a core material ID for a core material thread / core material set pair.
|
|
Sets the core skeleton. This function sets the core skeleton of the core model instance..
|
|
Stores user data. This function stores user data in the core model instance.
|
|
Delete the resources used by a core animation. The caller must ensure that the corresponding is not referenced anywhere otherwise unpredictable results will occur.
|
|
Delete the resources used by the named core animation. The name must be associated with a valid core animation Id with the function getAnimationId. The caller must ensure that the corresponding is not referenced anywhere otherwise unpredictable results will occur.
|
|
Delete the resources used by a core material. The caller must ensure that the corresponding is not referenced anywhere otherwise unpredictable results will occur.
|
|
Delete the resources used by the named core material. The name must be associated with a valid core material Id with the function getMaterialId. The caller must ensure that the corresponding is not referenced anywhere otherwise unpredictable results will occur.
|
|
Delete the resources used by a core mesh. The caller must ensure that the corresponding is not referenced anywhere otherwise unpredictable results will occur.
|
|
Delete the resources used by the named core mesh. The name must be associated with a valid core mesh Id with the function getMeshId. The caller must ensure that the corresponding is not referenced anywhere otherwise unpredictable results will occur.
|