26#ifndef TGUI_CANVAS_OPENGL3_HPP
27#define TGUI_CANVAS_OPENGL3_HPP
29#include <TGUI/Config.hpp>
30#include <TGUI/Backend/Renderer/OpenGL3/BackendTextureOpenGL3.hpp>
31#include <TGUI/Backend/Renderer/BackendRenderTarget.hpp>
32#include <TGUI/Widgets/ClickableWidget.hpp>
66 typedef std::shared_ptr<CanvasOpenGL3>
Ptr;
67 typedef std::shared_ptr<const CanvasOpenGL3>
ConstPtr;
77 CanvasOpenGL3(
const char* typeName =
"CanvasOpenGL3",
bool initRenderer =
true);
183 unsigned int m_textureId = 0;
184 unsigned int m_frameBuffer = 0;
187 std::shared_ptr<BackendTextureOpenGL3> m_backendTexture;
Base class for render targets.
Definition: BackendRenderTarget.hpp:48
Definition: CanvasOpenGL3.hpp:63
static CanvasOpenGL3::Ptr create(Layout2d size={"100%", "100%"})
Creates a new canvas widget.
CanvasOpenGL3(const CanvasOpenGL3 ©)
Copy constructor.
void draw(BackendRenderTarget &target, RenderStates states) const override
Draw the widget to a render target.
std::shared_ptr< CanvasOpenGL3 > Ptr
Shared widget pointer.
Definition: CanvasOpenGL3.hpp:66
Widget::Ptr clone() const override
Makes a copy of the widget if you don't know its exact type.
~CanvasOpenGL3()
Destructor.
unsigned int bindFramebuffer() const
Binds the framebuffer of the canvas.
std::shared_ptr< const CanvasOpenGL3 > ConstPtr
Shared constant widget pointer.
Definition: CanvasOpenGL3.hpp:67
bool canGainFocus() const override
Returns whether the widget can gain focus.
void setSize(const Layout2d &size) override
Changes the size of the widget.
CanvasOpenGL3(CanvasOpenGL3 &©)=default
Default move constructor.
static CanvasOpenGL3::Ptr copy(CanvasOpenGL3::ConstPtr canvas)
Makes a copy of another canvas.
Class to store the position or size of a widget.
Definition: Layout.hpp:284
Namespace that contains all TGUI functions and classes.
Definition: AbsoluteOrRelativeValue.hpp:36
States used for drawing.
Definition: RenderStates.hpp:39