PixelLightAPI  .
Public Member Functions
PLMesh::AnchorPoint Class Reference

An anchor points holds the index to a vertex or bone. More...

#include <AnchorPoint.h>

Inheritance diagram for PLMesh::AnchorPoint:
Inheritance graph
[legend]

List of all members.

Public Member Functions

PLMESH_API AnchorPoint (const PLCore::String &sName="", bool bType=0, PLCore::uint32 nID=0, AnchorPointManager *pManager=nullptr)
 Constructor.
virtual PLMESH_API ~AnchorPoint ()
 Destructor.
PLMESH_API bool GetType () const
 Returns the anchor type.
PLMESH_API void SetType (bool bType=0)
 Sets the anchor type.
PLMESH_API PLCore::uint32 GetID () const
 Returns the anchors vertex/bone ID.
PLMESH_API void SetID (PLCore::uint32 nID=0)
 Sets the anchors vertex/bone ID.
virtual PLMESH_API AnchorPointoperator= (const AnchorPoint &cSource)

Detailed Description

An anchor points holds the index to a vertex or bone.

Remarks:
SceneNode is the best example for it's usage. You can create anchor points for a mesh in the PixelLight mesh editor and if you want to get it's position in the world you just have to call the function GetAnchorPoint("MyAnchorPoint"). With this anchor points you are able to connect e.g. particle effects etc. to mesh vertices without to much effort. Bone anchor points have the advantage that you will also receive the current bone rotation.

Constructor & Destructor Documentation

PLMESH_API PLMesh::AnchorPoint::AnchorPoint ( const PLCore::String sName = "",
bool  bType = 0,
PLCore::uint32  nID = 0,
AnchorPointManager pManager = nullptr 
)

Constructor.

Parameters:
[in]sNameName of the anchor point
[in]bTypeAnchor type (0=vertex 1=bone)
[in]nIDID of the vertex/bone the anchor is attached to
[in]pManagerAnchor point manager using this element, can be a null pointer
Note:
  • If you provide the pointer to the owner manager the anchor point will check in the anchor point manager name list
virtual PLMESH_API PLMesh::AnchorPoint::~AnchorPoint ( ) [virtual]

Destructor.


Member Function Documentation

PLMESH_API bool PLMesh::AnchorPoint::GetType ( ) const

Returns the anchor type.

Returns:
Anchor type (0=vertex 1=bone)
PLMESH_API void PLMesh::AnchorPoint::SetType ( bool  bType = 0)

Sets the anchor type.

Parameters:
[in]bTypeAnchor type (0=vertex 1=bone)
PLMESH_API PLCore::uint32 PLMesh::AnchorPoint::GetID ( ) const

Returns the anchors vertex/bone ID.

Returns:
ID of the vertex/bone the anchor is attached to

Reimplemented from PLCore::Element< AnchorPoint >.

PLMESH_API void PLMesh::AnchorPoint::SetID ( PLCore::uint32  nID = 0)

Sets the anchors vertex/bone ID.

Parameters:
[in]nIDID of the vertex/bone the anchor is attached to
virtual PLMESH_API AnchorPoint& PLMesh::AnchorPoint::operator= ( const AnchorPoint cSource) [virtual]

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


PixelLight PixelLight 0.9.10-R1
Copyright (C) 2002-2011 by The PixelLight Team
Last modified Fri Dec 23 2011 15:51:20
The content of this PixelLight document is published under the
Creative Commons Attribution-NonCommercial-ShareAlike 3.0 Unported