1 | #pragma once
|
---|
2 |
|
---|
3 | //disable inheritance warning caused by multiple inheritance
|
---|
4 | #if _WIN32
|
---|
5 | #if _MSC_VER
|
---|
6 | #pragma warning(disable: 4250)
|
---|
7 | #endif
|
---|
8 | #endif
|
---|
9 |
|
---|
10 | #include "OgreRenderTechnique.h"
|
---|
11 | #include "Ogre.h"
|
---|
12 |
|
---|
13 | using namespace Ogre;
|
---|
14 |
|
---|
15 | struct PathMapClusters;
|
---|
16 | /**
|
---|
17 | @brief A technique that defines that the rendering of the object will use the path map technique.
|
---|
18 |
|
---|
19 | This rendering technique can add indirect lighting to the scene.
|
---|
20 | */
|
---|
21 | class OgrePathMapRenderTechnique : public OgreRenderTechnique
|
---|
22 | {
|
---|
23 | public:
|
---|
24 | /**
|
---|
25 | @brief Constructor.
|
---|
26 |
|
---|
27 | @param pass the pass after which shadowing passes should be added
|
---|
28 | @param parentRenderable the object to operate on
|
---|
29 | @param parentTechniqueGroup the TechniqueGroup this RenderedTechnique is attached to
|
---|
30 | */
|
---|
31 | OgrePathMapRenderTechnique(Pass* pass,
|
---|
32 | OgreRenderable* parentRenderable,
|
---|
33 | OgreTechniqueGroup* parentTechniqueGroup
|
---|
34 | );
|
---|
35 | /**
|
---|
36 | @brief Destructor.
|
---|
37 | */
|
---|
38 | ~OgrePathMapRenderTechnique();
|
---|
39 |
|
---|
40 | //inherited
|
---|
41 | virtual void update(unsigned long frameNum);
|
---|
42 |
|
---|
43 | protected:
|
---|
44 | /**
|
---|
45 | @brief the new pass created by this technique
|
---|
46 | */
|
---|
47 | Pass* pathMapPass;
|
---|
48 | /**
|
---|
49 | @brief the PathMapClusters structure that belongs to the subentity renderable
|
---|
50 | */
|
---|
51 | PathMapClusters* clusters;
|
---|
52 | /**
|
---|
53 | @brief the weight index lookup map created by this technique
|
---|
54 | */
|
---|
55 | Texture* weightIndexTexture;
|
---|
56 | /**
|
---|
57 | @brief create a weight index lookup map
|
---|
58 | */
|
---|
59 | void createWeightIndexTexture();
|
---|
60 | };
|
---|
61 |
|
---|
62 | /**
|
---|
63 | @brief RenderTechniqueFactory to create OgrePathMapRenderTechnique instances.
|
---|
64 | */
|
---|
65 | class OgrePathMapRenderTechniqueFactory : public RenderTechniqueFactory
|
---|
66 | {
|
---|
67 | public:
|
---|
68 |
|
---|
69 | OgrePathMapRenderTechniqueFactory();
|
---|
70 |
|
---|
71 | OgreRenderTechnique* createInstance(IllumTechniqueParams* params,
|
---|
72 | Pass* pass,
|
---|
73 | OgreRenderable* parentRenderable,
|
---|
74 | OgreTechniqueGroup* parentTechniqueGroup);
|
---|
75 | };
|
---|
76 |
|
---|