#pragma once //disable inheritance warning caused by multiple inheritance #if _WIN32 #if _MSC_VER #pragma warning(disable: 4250) #endif #endif #include "OgreRenderingRun.h" #include "CubeMapRenderingRun.h" #include "OgreSharedRuns.h" /** @brief ColorCubeMapRenderingRun used in an OGRE environment. */ class OgreCubeMapRenderingRun : public OgreRenderingRun, public CubeMapRenderingRun { public: /** @brief Constructor. @param sharedRuns a pointer to the OgreSharedRuns this run belongs to @param name the name of the cubemap texture to be created @param startFrame adds an offset to the current frame number to help evenly distribute updates between frames @param updateInterval update frequency @param resolution cubemap resolution @param useDistCalc flag to skip cube face update if object is far away @param useFaceAngleCalc flag to skip cube face update if face is neglible @param distTolerance distance tolerance used in face skip @param angleTolerance angle tolerance used in face skip @param updateAllFace defines if all cubemap faces should be updated in a frame or only one face per frame */ OgreCubeMapRenderingRun(OgreSharedRuns* sharedRuns, String name, unsigned long startFrame, unsigned long updateInterval, unsigned int resolution, bool useDistCalc, bool useFaceAngleCalc, float distTolerance, float angleTolerance, bool updateAllFace, bool renderSelf, bool renderEnvironment, String selfMaterial, String environmentMaterial, RenderingRunType cubemapRunType); /** @brief returns the name of the resulting color cubemap texture */ String getCubeMapTextureName(){return name;} protected: /** @brief a pointer to the OgreSharedRuns this run belongs to */ OgreSharedRuns* sharedRuns; /** @brief the name of the cubemap texture that was created by this run */ String name; /** @brief a pointer to the cubemap texture that was created by this run */ Texture* cubemapTexture; String selfMaterial; bool useSelfMaterial; String environmentMaterial; bool useEnvMaterial; RenderingRunType cubemapRunType; //inherited inline void createCubeMap(); //inherited inline void updateCubeFace(int facenum); //inherited bool faceNeedsUpdate(int facenum); };