~baltix/+junk/irrlicht-test

« back to all changes in this revision

Viewing changes to source/Irrlicht/CBoneSceneNode.h

  • Committer: Mantas Kriaučiūnas
  • Date: 2011-07-18 13:06:25 UTC
  • Revision ID: mantas@akl.lt-20110718130625-c5pvifp61e7kj1ol
Included whole irrlicht SVN libraries to work around launchpad recipe issue with quilt, see https://answers.launchpad.net/launchpad/+question/165193

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
// Copyright (C) 2002-2011 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
 
 
12
namespace irr
 
13
{
 
14
namespace 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