[115] | 1 | #ifndef _TestCullingTerrainApplication_H__
|
---|
| 2 | #define _TestCullingTerrainApplication_H__
|
---|
| 3 |
|
---|
[61] | 4 | #include "CEGUIForwardRefs.h"
|
---|
[139] | 5 | #include <OgreRenderTargetListener.h>
|
---|
[61] | 6 | #include "ExampleApplication.h"
|
---|
[139] | 7 |
|
---|
[107] | 8 | #include "OgreTerrainContentGenerator.h"
|
---|
[133] | 9 | #include "TerrainFrameListener.h"
|
---|
[61] | 10 |
|
---|
[99] | 11 | class VisualizationRenderTargetListener: public RenderTargetListener
|
---|
| 12 | {
|
---|
| 13 | public:
|
---|
| 14 | VisualizationRenderTargetListener(SceneManager *sceneMgr);
|
---|
| 15 |
|
---|
| 16 | protected:
|
---|
| 17 | void preViewportUpdate (const RenderTargetViewportEvent &evt);
|
---|
| 18 | void postRenderTargetUpdate (const RenderTargetEvent &evt);
|
---|
| 19 |
|
---|
| 20 | SceneManager *mSceneMgr;
|
---|
[139] | 21 |
|
---|
| 22 | ShadowTechnique mSavedShadowTechnique;
|
---|
| 23 | ColourValue mSavedAmbientLight;
|
---|
[99] | 24 | };
|
---|
| 25 |
|
---|
[61] | 26 |
|
---|
| 27 | class TestCullingTerrainApplication : public ExampleApplication
|
---|
| 28 | {
|
---|
| 29 | public:
|
---|
[145] | 30 | TestCullingTerrainApplication();
|
---|
[61] | 31 | ~TestCullingTerrainApplication();
|
---|
| 32 |
|
---|
| 33 | protected:
|
---|
[99] | 34 | //-- inherited from ExampleApplication
|
---|
| 35 | bool setup();
|
---|
[85] | 36 | void createScene();
|
---|
| 37 | void createFrameListener();
|
---|
[99] | 38 | void createCamera();
|
---|
| 39 | //void createViewports();
|
---|
| 40 |
|
---|
| 41 | virtual void createRenderTargetListener();
|
---|
| 42 |
|
---|
| 43 | /** cegui setup */
|
---|
[85] | 44 | void setupGui();
|
---|
[61] | 45 |
|
---|
| 46 | CEGUI::OgreCEGUIRenderer *mGUIRenderer;
|
---|
| 47 | CEGUI::System *mGUISystem;
|
---|
| 48 |
|
---|
[87] | 49 | Vector3 mMinTranslation;
|
---|
| 50 | Vector3 mMaxTranslation;
|
---|
| 51 |
|
---|
| 52 | Vector3 mMinAngle;
|
---|
[61] | 53 | Vector3 mMaxAngle;
|
---|
| 54 |
|
---|
[82] | 55 | TerrainContentGenerator *mTerrainContentGenerator;
|
---|
[99] | 56 |
|
---|
[100] | 57 | Camera *mVizCamera;
|
---|
| 58 | SceneNode *mCamNode;
|
---|
[109] | 59 | Light *mSunLight;
|
---|
[75] | 60 |
|
---|
[133] | 61 | TerrainFrameListener *mTerrainFrameListener;
|
---|
[139] | 62 | ColourValue mAmbientLight;
|
---|
| 63 | //VisualizationRenderTargetListener *mVizRenderTargetListener;
|
---|
[130] | 64 |
|
---|
[61] | 65 | private:
|
---|
| 66 | void chooseSceneManager(void);
|
---|
[115] | 67 | };
|
---|
| 68 |
|
---|
| 69 | #endif // TestCullingTerrainApplication |
---|