Om
1.0.0
A universal framework for multimedia simulation
|
A class that enables render-to-texture for OpenGL by specifying textures and their attachment points. More...
#include <omGraphicsOpenGLFramebuffer.h>
Public Member Functions | |
~OpenGLFramebuffer () | |
Destroy this framebuffer and all associated state. More... | |
virtual Bool | getTarget (const FramebufferAttachment &attachment, Shared< DeviceTexture > &texture, TextureFace &face) const |
Get the texture and texture face that is attached at the specified framebuffer attachment point. More... | |
virtual Bool | setTarget (const FramebufferAttachment &attachment, const Shared< DeviceTexture > &newTarget, TextureFace face=TextureFace::FRONT) |
Set the target texture for the specified framebuffer attachment point. More... | |
virtual void | clearTargets () |
Remove all attached target textures from this framebuffer. More... | |
virtual Size | getMinimumSize (Index dimension) const |
Return the minimum size of the framebuffer in pixels along the specified dimension index. More... | |
virtual Size | getMaximumSize (Index dimension) const |
Return the maximum size of the framebuffer in pixels along the specified dimension index. More... | |
virtual Bool | isValid () const |
Return whether or not the framebuffer is valid and can be used as a render target. More... | |
OpenGLID | getID () const |
Get a unique integral identifier for this framebuffer. More... | |
Public Member Functions inherited from om::graphics::textures::DeviceFramebuffer | |
Size | getSize (Index dimension) const |
Return the minimum size of the framebuffer in pixels along the specified dimension index. More... | |
Public Member Functions inherited from om::graphics::devices::DeviceResource | |
virtual | ~DeviceResource () |
Destroy a device object, releasing all internal state. More... | |
GraphicsContext * | getContext () const |
Return a pointer to the graphics context associated with this DeviceResource. More... | |
Additional Inherited Members | |
Protected Member Functions inherited from om::graphics::textures::DeviceFramebuffer | |
DeviceFramebuffer (devices::GraphicsContext *context) | |
Create an empty framebuffer for the given context with no attached textures. More... | |
Protected Member Functions inherited from om::graphics::devices::DeviceResource | |
DeviceResource (GraphicsContext *newContext) | |
Create a new device object that is associated with the specified graphics context. More... | |
A class that enables render-to-texture for OpenGL by specifying textures and their attachment points.
om::graphics::devices::opengl::OpenGLFramebuffer::~OpenGLFramebuffer | ( | ) |
Destroy this framebuffer and all associated state.
|
virtual |
Get the texture and texture face that is attached at the specified framebuffer attachment point.
If there is no attachment for that attachment point, the method has no effect and returns FALSE. Otherwise, the target texture and face are written to the output parameters and TRUE is returned.
Implements om::graphics::textures::DeviceFramebuffer.
|
virtual |
Set the target texture for the specified framebuffer attachment point.
If the specified Texture is valid and supports the specified texture face, and if the specified attachment point is supported and valid, the texture is used as the target for the specified attachment point and TRUE is returned indicating success. Otherwise, FALSE is returned indicating failure, leaving the framebuffer unchanged.
Implements om::graphics::textures::DeviceFramebuffer.
|
virtual |
Remove all attached target textures from this framebuffer.
Implements om::graphics::textures::DeviceFramebuffer.
|
virtual |
Return the minimum size of the framebuffer in pixels along the specified dimension index.
Implements om::graphics::textures::DeviceFramebuffer.
|
virtual |
Return the maximum size of the framebuffer in pixels along the specified dimension index.
Implements om::graphics::textures::DeviceFramebuffer.
|
virtual |
Return whether or not the framebuffer is valid and can be used as a render target.
Implements om::graphics::devices::DeviceResource.
|
inline |
Get a unique integral identifier for this framebuffer.