aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/src/others/irrlicht-1.8.1/source/Irrlicht/CBoneSceneNode.h
diff options
context:
space:
mode:
Diffstat (limited to 'src/others/irrlicht-1.8.1/source/Irrlicht/CBoneSceneNode.h')
-rw-r--r--src/others/irrlicht-1.8.1/source/Irrlicht/CBoneSceneNode.h79
1 files changed, 79 insertions, 0 deletions
diff --git a/src/others/irrlicht-1.8.1/source/Irrlicht/CBoneSceneNode.h b/src/others/irrlicht-1.8.1/source/Irrlicht/CBoneSceneNode.h
new file mode 100644
index 0000000..79b94ef
--- /dev/null
+++ b/src/others/irrlicht-1.8.1/source/Irrlicht/CBoneSceneNode.h
@@ -0,0 +1,79 @@
1// Copyright (C) 2002-2012 Nikolaus Gebhardt
2// This file is part of the "Irrlicht Engine".
3// For conditions of distribution and use, see copyright notice in irrlicht.h
4
5#ifndef __C_BONE_SCENE_NODE_H_INCLUDED__
6#define __C_BONE_SCENE_NODE_H_INCLUDED__
7
8// Used with SkinnedMesh and IAnimatedMeshSceneNode, for boned meshes
9
10#include "IBoneSceneNode.h"
11
12namespace irr
13{
14namespace scene
15{
16
17 class CBoneSceneNode : public IBoneSceneNode
18 {
19 public:
20
21 //! constructor
22 CBoneSceneNode(ISceneNode* parent, ISceneManager* mgr,
23 s32 id=-1, u32 boneIndex=0, const c8* boneName=0);
24
25 //! Returns the index of the bone
26 virtual u32 getBoneIndex() const;
27
28 //! Sets the animation mode of the bone. Returns true if successful.
29 virtual bool setAnimationMode(E_BONE_ANIMATION_MODE mode);
30
31 //! Gets the current animation mode of the bone
32 virtual E_BONE_ANIMATION_MODE getAnimationMode() const;
33
34 //! returns the axis aligned bounding box of this node
35 virtual const core::aabbox3d<f32>& getBoundingBox() const;
36
37 /*
38 //! Returns the relative transformation of the scene node.
39 //virtual core::matrix4 getRelativeTransformation() const;
40 */
41
42 virtual void OnAnimate(u32 timeMs);
43
44 virtual void updateAbsolutePositionOfAllChildren();
45
46 //! Writes attributes of the scene node.
47 virtual void serializeAttributes(io::IAttributes* out, io::SAttributeReadWriteOptions* options=0) const;
48
49 //! Reads attributes of the scene node.
50 virtual void deserializeAttributes(io::IAttributes* in, io::SAttributeReadWriteOptions* options=0);
51
52 //! How the relative transformation of the bone is used
53 virtual void setSkinningSpace( E_BONE_SKINNING_SPACE space )
54 {
55 SkinningSpace=space;
56 }
57
58 virtual E_BONE_SKINNING_SPACE getSkinningSpace() const
59 {
60 return SkinningSpace;
61 }
62
63 private:
64 void helper_updateAbsolutePositionOfAllChildren(ISceneNode *Node);
65
66 u32 BoneIndex;
67
68 core::aabbox3d<f32> Box;
69
70 E_BONE_ANIMATION_MODE AnimationMode;
71 E_BONE_SKINNING_SPACE SkinningSpace;
72 };
73
74
75} // end namespace scene
76} // end namespace irr
77
78#endif
79