Public Member Functions
ChainRoot Class Reference

Detailed Description

The ChainRoot object represents the root of a skeleton chain.

See also:
ChainElement,ChainBone
Example:
        using namespace XSI;
        Application app;
        Model root = app.GetActiveSceneRoot();

        ChainRoot myChainRoot;
        root.Add3DChain(    MATH::CVector3(0,0,0),
                            MATH::CVector3(1,0,0),
                            MATH::CVector3(0,0,1),
                            L"",
                            myChainRoot);

        ChainBone myChainBone1;
        myChainRoot.AddBone(MATH::CVector3(3,3,3),siChainBonePin,L"",myChainBone1);

        ChainBone myChainBone2;
        myChainRoot.AddBone(MATH::CVector3(6,0,0),siChainBoneBallJoint,L"",myChainBone2);

        app.LogMessage(CString(L"The chain root name is : ") + myChainRoot.GetFullName());

#include <xsi_chainroot.h>

Inheritance diagram for ChainRoot:
Inheritance graph
[legend]

List of all members.

Public Member Functions

  ChainRoot ()
  ~ChainRoot ()
  ChainRoot (const CRef &in_ref)
  ChainRoot (const ChainRoot &in_obj)
bool  IsA (siClassID in_ClassID) const
siClassID  GetClassID () const
ChainRoot operator= (const ChainRoot &in_obj)
ChainRoot operator= (const CRef &in_ref)
CRefArray  GetBones () const
CStatus  AddBone (const MATH::CVector3 &in_newEffPos, siChainBoneType in_BoneType, const CString &in_name, ChainBone &io_bone)

Constructor & Destructor Documentation

ChainRoot ( )

Default constructor.

~ChainRoot ( )

Default destructor.

ChainRoot ( const CRef in_ref )

Constructor.

Parameters:
in_ref constant reference object.
ChainRoot ( const ChainRoot in_obj )

Copy constructor.

Parameters:
in_obj constant class object.

Member Function Documentation

bool IsA ( siClassID  in_ClassID ) const [virtual]

Returns true if a given class type is compatible with this API class.

Parameters:
in_ClassID class type.
Returns:
true if the class is compatible, false otherwise.

Reimplemented from ChainElement.

siClassID GetClassID ( ) const [virtual]

Returns the type of the API class.

Returns:
The class type.

Reimplemented from ChainElement.

ChainRoot& operator= ( const ChainRoot in_obj )

Creates an object from another object. The newly created object is set to empty if the input object is not compatible.

Parameters:
in_obj constant class object.
Returns:
The new ChainRoot object.
ChainRoot& operator= ( const CRef in_ref )

Creates an object from a reference object. The newly created object is set to empty if the input reference object is not compatible.

Parameters:
in_ref constant class object.
Returns:
The new ChainRoot object.

Reimplemented from ChainElement.

CRefArray GetBones ( ) const

Returns an array containing references to ChainBone contained in this skeleton chain.

Returns:
Array of references to ChainBone objects contained in this skeleton chain.
CStatus AddBone ( const MATH::CVector3 in_newEffPos,
siChainBoneType  in_BoneType,
const CString in_name,
ChainBone io_bone 
)

Adds a ChainBone element at the end of this chain.

Returns:
Array of references to the ChainBone objects contained in this skeleton chain.
Parameters:
in_newEffPos The new effector position.
in_BoneType The type of bone to add.
in_name The name of the new chain.
io_bone The new bone.
Returns:
CStatus::OK success
CStatus::Fail failure

The documentation for this class was generated from the following file: