Line | |
---|
1 | /**
|
---|
2 | \file
|
---|
3 | TerrainContentGenerator.h
|
---|
4 | */
|
---|
5 | #include "ExampleApplication.h"
|
---|
6 |
|
---|
7 | class RayQueryExecutor
|
---|
8 | {
|
---|
9 | public:
|
---|
10 | RayQueryExecutor( SceneManager *sm );
|
---|
11 | ~RayQueryExecutor( );
|
---|
12 | bool executeRayQuery( Vector3 *result, const Vector3 &pos, const Vector3 &dir );
|
---|
13 | protected:
|
---|
14 | RaySceneQuery *mRaySceneQuery;
|
---|
15 | };
|
---|
16 |
|
---|
17 | class TerrainContentGenerator
|
---|
18 | {
|
---|
19 | public:
|
---|
20 | TerrainContentGenerator( SceneManager *sm, RayQueryExecutor *rayQueryEx );
|
---|
21 | /** generates a the scene hierarchy with random values
|
---|
22 | @param number of objects to generate
|
---|
23 | */
|
---|
24 | void generateScene( int numObjects );
|
---|
25 | /** |
---|
26 | generates a new scene object |
---|
27 | @param tranlationRatio ratio between minimal and maximal possible translation |
---|
28 | @param rotationRatio ratio between minimal and maximal possible rotation |
---|
29 | @idx the index of the new object |
---|
30 | @entName the name of the object entity |
---|
31 | */ |
---|
32 | void generateSceneObject( const Vector3 &translationRatio, const Vector3 &rotationRatio,
|
---|
33 | const int idx, const String &entName );
|
---|
34 |
|
---|
35 | protected:
|
---|
36 |
|
---|
37 | Real mMinAngle;
|
---|
38 | Real mMaxAngle;
|
---|
39 | Vector3 mMaxTranslation;
|
---|
40 | Vector3 mMinTranslation;
|
---|
41 |
|
---|
42 | RayQueryExecutor *mRayQueryExecutor;
|
---|
43 | SceneManager *mSceneMgr;
|
---|
44 | int mCount; // The number of objects on the screen
|
---|
45 | };
|
---|
46 |
|
---|
Note: See
TracBrowser
for help on using the repository browser.