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

skybox.h

Go to the documentation of this file.
00001 /***************************************************************************
00002                        skybox.h  -  Simple skybox class
00003                              -------------------
00004     begin                : Mon Nov 19 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, skybox.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 __NESKYBOX_H
00028 #define __NESKYBOX_H
00029 
00030 
00031 #include "base.h"
00032 #include "sceneentity.h"
00033 #include "material.h"
00034 #include "vertexbuffer.h"
00035 #include "polygonbuffer.h"
00036 
00037 
00044 namespace NeoEngine
00045 {
00046 
00047 
00052 class NEOENGINE_API SkyBox : public SceneEntity
00053 {
00054     public:
00055         DefineVisitable()
00056 
00057     public:
00058 
00062         enum SKYBOXPLANE
00063         {
00065           FRONT                                       = 0,
00066 
00068           BACK                                        = 1,
00069 
00071           LEFT                                        = 2,
00072 
00074           RIGHT                                       = 3,
00075 
00077           UP                                          = 4,
00078 
00080           DOWN                                        = 5,
00081 
00083           NUMPLANES                                   = 6
00084         };
00085 
00086 
00087     protected:
00088 
00090         VertexBufferPtr                               m_apkVertexBuffer[NUMPLANES];
00091 
00093         PolygonStripBufferPtr                         m_pkPolygonBuffer;
00094 
00096         MaterialPtr                                   m_apkMaterial[NUMPLANES];
00097 
00098 
00099 
00100     public:
00101 
00102 
00107                                                       SkyBox( float fSize = 100.0f, const Vector3d &rkOffset = Vector3d::ZERO );
00108 
00112         virtual                                      ~SkyBox();
00113 
00114 
00120         void                                          SetMaterial( SKYBOXPLANE ePlane, MaterialPtr &pkMaterial );
00121 
00125         virtual bool                                  Render( Frustum *pkFrustum = 0, bool bForce = false );
00126 };
00127 
00128 
00129 };
00130 
00131 
00132 #endif

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