You.i Engine
YiGLFramebufferObject.h
Go to the documentation of this file.
1 // © You i Labs Inc. 2000-2017. All rights reserved.
2 #ifndef _YI_GL_FRAMEBUFFER_OBJECT_H_
3 #define _YI_GL_FRAMEBUFFER_OBJECT_H_
4 
7 
13 class CYIAsset;
14 
19 {
20 public:
27  CYIGLFramebufferObject(bool screenBuffer = false);
28 
34  virtual ~CYIGLFramebufferObject();
35 
36  //Inherited from IYIGPUObject
37  virtual void Load(const std::shared_ptr<CYIAssetHardware> &pAsset) override;
38  virtual void Unload() override;
39  virtual void Use() const override;
40 
41 
42  bool HasDepthStencil() const;
43  bool HasColor() const;
44 
45 protected:
46  //Inherited from IYIGPUObject
47  virtual void Generate() override;
48  virtual void Free() override;
49  virtual void InvalidateHandle() override;
50 
56 
57  //If the platform doesn't do depth textures, the fbo will own a depth render buffer
59 };
60 
63 #endif // _YI_GL_FRAMEBUFFER_OBJECT_H_
bool HasColor() const
An abstract class for common OpenGL buffer functionality.
Definition: YiGLAbstractBufferObject.h:17
GLuint m_depthBufferId
Definition: YiGLFramebufferObject.h:58
virtual void Load(const std::shared_ptr< CYIAssetHardware > &pAsset) override
CYIGLFramebufferObject(bool screenBuffer=false)
virtual void Use() const override
IYIGPUObject implementation for OpenGL Framebuffers.
Definition: YiGLFramebufferObject.h:18
bool HasDepthStencil() const
virtual void Unload() override
bool m_bScreenBuffer
Definition: YiGLFramebufferObject.h:53
virtual void InvalidateHandle() override
bool m_bPlatformSupportsPackedDepthStencil
Definition: YiGLFramebufferObject.h:55
bool m_bHasColor
Definition: YiGLFramebufferObject.h:51
virtual void Generate() override
bool m_bPlatformSupportsDepthTextures
Definition: YiGLFramebufferObject.h:54
Base class for any asset. An asset provides functions for dynamically loading and unloading itself an...
Definition: YiAsset.h:33
bool m_bHasDepthStencil
Definition: YiGLFramebufferObject.h:52
virtual void Free() override
virtual ~CYIGLFramebufferObject()