FramebufferAttachment.h
Go to the documentation of this file.
#pragma once
#include <string>
#include <glbinding/gl/types.h>
#include <globjects/base/Referenced.h>
#include <globjects/globjects_api.h>
namespace globjects
{
class AttachedTexture;
class AttachedRenderbuffer;
class Framebuffer;
class GLOBJECTS_API FramebufferAttachment : public Referenced
{
public:
FramebufferAttachment(Framebuffer * fbo, gl::GLenum attachment);
gl::GLenum attachment() const;
gl::GLint getParameter(gl::GLenum pname) const;
virtual bool isTextureAttachment() const;
virtual bool isRenderBufferAttachment() const;
AttachedTexture * asTextureAttachment();
const AttachedTexture * asTextureAttachment() const;
AttachedRenderbuffer * asRenderBufferAttachment();
const AttachedRenderbuffer * asRenderBufferAttachment() const;
std::string attachmentString() const;
protected:
Framebuffer * m_fbo; // TODO: weak pointer?
gl::GLenum m_attachment;
};
} // namespace globjects
Referenced.h
globjects::AttachedTexture
Encapsulates texture attachments of a frame buffer object.
Definition: AttachedTexture.h:26
globjects::FramebufferAttachment::m_fbo
Framebuffer * m_fbo
Definition: FramebufferAttachment.h:49
globjects
Contains all the classes that wrap OpenGL functionality.
globjects::FramebufferAttachment
Wraps attachments to a FrameBufferObject.
Definition: FramebufferAttachment.h:29
globjects::Framebuffer
Enables creation of arbitrary render targets that are not directly drawn on the screen.
Definition: Framebuffer.h:46
globjects::FramebufferAttachment::m_attachment
gl::GLenum m_attachment
Definition: FramebufferAttachment.h:50
globjects::AttachedRenderbuffer
Wrapper of render buffer attachments of a frame buffer object.
Definition: AttachedRenderbuffer.h:27
globjects::Referenced
Superclass for all classes that use reference counting in globjects.
Definition: Referenced.h:22