X-Git-Url: http://git.tdb.fi/?p=libs%2Fgl.git;a=blobdiff_plain;f=source%2Fenvironmentmap.h;h=6fdd3749a9e316e6cad18cf6caeccc37613ad86c;hp=aa95630f1d4886815930201abbdbea8c4dd3c999;hb=HEAD;hpb=74e1414b1f86d6be0b0100b196b9b112cdda0435 diff --git a/source/environmentmap.h b/source/environmentmap.h deleted file mode 100644 index aa95630f..00000000 --- a/source/environmentmap.h +++ /dev/null @@ -1,51 +0,0 @@ -#ifndef MSP_GL_ENVIRONMENTMAP_H_ -#define MSP_GL_ENVIRONMENTMAP_H_ - -#include "camera.h" -#include "effect.h" -#include "framebuffer.h" -#include "matrix.h" -#include "programdata.h" -#include "renderbuffer.h" -#include "texturecube.h" -#include "vector.h" - -namespace Msp { -namespace GL { - -class Renderable; - -/** -Creates a cube map texture of the surroundings of the renderable. This texture -can then be used to implement effects such as reflections or refractions. - -If the EnvironmentMap is used in a Pipeline, it's worth noting that the cube -map will be prepared outside of any rendering pass. It's recommended to use -another Pipeline to define which passes should be used to render the -environment. -*/ -class EnvironmentMap: public Effect -{ -private: - unsigned size; - Renderable &environment; - TextureCube env_tex; - Renderbuffer depth_buf; - Framebuffer fbo[6]; - Camera camera; - mutable ProgramData shdata; - bool rendered; - -public: - EnvironmentMap(unsigned size, Renderable &rend, Renderable &env); - - virtual void setup_frame(Renderer &); - virtual void finish_frame(); - - virtual void render(Renderer &, const Tag & = Tag()) const; -}; - -} // namespace GL -} // namespace Msp - -#endif