Main Page | Namespace List | Class Hierarchy | Alphabetical List | Class List | File List | Namespace Members | Class Members | Related Pages

skeleton.h

Go to the documentation of this file.
00001 /***************************************************************************
00002                 skeleton.h  -  Skeleton as a hierarchy of bone nodes
00003                              -------------------
00004     begin                : Sun Jan 26 2003
00005     copyright            : (C) 2003 by Realit Rift Studios
00006     email                : mattias@realityrift.com
00007  ***************************************************************************
00008 
00009  The contents of this file are subject to the Mozilla Public License Version
00010  1.1 (the "License"); you may not use this file except in compliance with
00011  the License. You may obtain a copy of the License at 
00012  http://www.mozilla.org/MPL/
00013 
00014  Software distributed under the License is distributed on an "AS IS" basis,
00015  WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
00016  for the specific language governing rights and limitations under the
00017  License.
00018 
00019  The Original Code is the NeoEngine, skeleton.h
00020 
00021  The Initial Developer of the Original Code is Mattias Jansson.
00022  Portions created by Mattias Jansson are Copyright (C) 2003
00023  Reality Rift Studios. All Rights Reserved.
00024 
00025  ***************************************************************************/
00026 
00027 #ifndef __NESKELETON_H
00028 #define __NESKELETON_H
00029 
00030 
00037 #include "base.h"
00038 #include "scenenode.h"
00039 #include "bone.h"
00040 #include "skeletonanimator.h"
00041 
00042 #include <string>
00043 #include <vector>
00044 
00045 
00046 namespace NeoEngine
00047 {
00048 
00049 
00050 // External classes
00051 class BoneAdaptor;
00052 
00053 
00054 #ifdef WIN32
00055 
00056 #  ifdef _MSC_VER
00057 #    pragma warning( disable : 4231 )
00058 #  endif
00059 
00060 #  ifndef __HAVE_VECTOR_NEABONEDAPTOR
00061      UDTVectorEXPIMP( class BoneAdaptor* );
00062 #    define __HAVE_VECTOR_NEBONEADAPTOR
00063 #  endif
00064 
00065 #endif
00066 
00067 
00073 class NEOENGINE_API Skeleton : public SceneNode, public SkeletonAnimatorController
00074 {
00075     public:
00076 
00077         DefineVisitable();
00078 
00079 
00080     public:
00081 
00083         Bone                                         *m_pkRoot;
00084 
00086         Bone                                        **m_ppkBones;
00087 
00089         unsigned int                                  m_uiNumBones;
00090 
00092         std::vector< BoneAdaptor* >                   m_vpkAdaptors;
00093 
00095         bool                                          m_bRenderSkeleton;
00096 
00097 
00100                                                       Skeleton();
00101 
00106                                                       Skeleton( Skeleton &rkSkeleton );
00107 
00110         virtual                                      ~Skeleton();
00111 
00116         virtual void                                  Update( float fDeltaTime );
00117 
00122         virtual SceneNode                            *Duplicate();
00123 
00130         virtual bool                                  Render( Frustum *pkFrustum = 0, bool bForce = false );
00131 
00136         void                                          AttachAdaptor( BoneAdaptor *pkAdaptor );
00137 
00142         void                                          DetachAdaptor( BoneAdaptor *pkAdaptor );
00143 };
00144 
00145 
00146 };
00147 
00148 
00149 #endif

Generated on Wed Jan 21 14:21:07 2004 for NeoEngine by doxygen 1.3.5