#ifndef __VISUALIZATION_H #define __VISUALIZATION_H #include "common.h" namespace CHCDemoEngine { class Bvh; class Camera; class RenderState; class AxisAlignedBox3; class GLUquadric; /** Abstract class implementing a scene traversal for rendering. */ class Visualization { public: /** Main constructor taking a bvh, a camera, a visualization camera and the current render state as parameters */ Visualization(Bvh *bvh, Camera *camera, Camera *vizCamera, RenderState *state); ~Visualization(); /** Renders the visualizatioin */ void Render(); /** Sets the scene hierarchy. */ void SetHierarchy(Bvh *bvh); /** Sets the visualization camera. */ void SetVizCamera(Camera *cam) {mVizCamera = cam;} /** Sets the currently used scene camera. */ void SetCamera(Camera *cam) {mCamera = cam;} /** Sets the current render state */ void SetRenderState(RenderState *state); /** Sets the currentframe id */ void SetFrameId(int frameId); protected: /** Renders a camera frustum. */ void RenderFrustum(); //////////// //-- members /// the current camera Camera *mCamera; /// the visualization camera Camera *mVizCamera; /// the root of the scene hierarchy Bvh *mBvh; /// the current render state RenderState *mRenderState; /// the current frame id int mFrameId; }; } #endif // VISUALIZATION_H