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

room.h

Go to the documentation of this file.
00001 /***************************************************************************
00002                    room.h  -  Space partitioning base classes
00003                              -------------------
00004     begin                : Tue Oct 30 2001
00005     copyright            : (C) 2001 by Reality 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, room.h
00020 
00021  The Initial Developer of the Original Code is Mattias Jansson.
00022  Portions created by Mattias Jansson are Copyright (C) 2001
00023  Reality Rift Studios. All Rights Reserved.
00024 
00025  ***************************************************************************/
00026 
00027 #ifndef __NEROOM_H
00028 #define __NEROOM_H
00029 
00030 
00037 #include "base.h"
00038 #include "scenenode.h"
00039 #include "module.h"
00040 #include "vertexbuffer.h"
00041 #include "polygonbuffer.h"
00042 
00043 #include <string>
00044 
00045 
00046 namespace NeoEngine
00047 {
00048 
00049 
00050 // External classes
00051 class Ray;
00052 
00053 
00061 class NEOENGINE_API Room : public SceneNode
00062 {
00063     public:
00064 
00065         DefineVisitable();
00066 
00067     protected:
00068 
00070         std::vector< SceneNode* >                     m_vpkGlobalNodes;
00071 
00072 
00073     public:
00074 
00075 
00080                                                       Room( const HashString &rstrName = "" );
00081 
00084         virtual                                      ~Room();
00085 
00091         virtual int                                   AttachGlobalNode( SceneNode *pkNode );
00092 
00098         virtual int                                   DetachGlobalNode( SceneNode *pkNode );
00099 
00106         virtual int                                   AttachNode( SceneNode *pkNode, bool bKeepWorldSRT = false );
00107 
00113         virtual int                                   DetachNode( SceneNode *pkNode );
00114 
00121         virtual bool                                  Render( Frustum *pkFrustum = 0, bool bForce = false );
00122 
00129         virtual void                                  AddGeometry( const PolygonBufferPtr &pkPolygonBuffer, const VertexBufferPtr &pkVertexBuffer, const MaterialPtr &pkMaterial );
00130 
00138         virtual void                                  SliceGeometry( const NeoEngine::Vector3d &rkV0, const NeoEngine::Vector3d &rkV1, const NeoEngine::Vector3d &rkV2, std::vector< NeoEngine::Vector3d > *pvkPoints );
00139 };
00140 
00141 
00147 class NEOENGINE_API RoomManager
00148 {
00149     protected:
00150 
00152         std::vector< ModulePtr >                      m_vpkModules;
00153 
00154 
00155     public:
00156 
00157 
00160                                                       RoomManager();
00161 
00164         virtual                                      ~RoomManager();
00165 
00171         virtual ModulePtr                             LoadModule( const HashString &rstrName );
00172 
00178         virtual Room                                 *CreateRoom( const HashString &rstrType );
00179 };
00180 
00181 
00182 };
00183 
00184 
00185 #endif

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