Rune Engine  Version 0.2.7-alpha
Documentation for how to make games using the Rune Engine.
rune::FrameBuffer Class Reference

An off screen frame buffer that can be bound and rendered to. More...

#include <frameBuffer.h>

Public Member Functions

 FrameBuffer ()
 Default constructor to initialize an opengl frame buffer.
 
 ~FrameBuffer ()
 Default destructor to clean up frame buffer.
 
void setSize (rune::Vec2 newSize)
 Set the size of the frame buffer in pixels. More...
 
rune::Vec2 getSize (void)
 Get the size of the frame buffer in pixels. More...
 
void invalidate ()
 Tell the frame buffer it is invalid and should be recreated.
 
void bind ()
 Bind the frame buffer for drawing.
 
void unbind ()
 Unbind the frame buffer for drawing.
 
unsigned int getColorBuffer ()
 Get a handle to the color buffer for drawing. More...
 

Detailed Description

An off screen frame buffer that can be bound and rendered to.

Author
Thomas Montano
Date
June 30 2020

Member Function Documentation

◆ getColorBuffer()

unsigned int rune::FrameBuffer::getColorBuffer ( )

Get a handle to the color buffer for drawing.

Returns
An unsigned integer handle that references the color buffer.

◆ getSize()

rune::Vec2 rune::FrameBuffer::getSize ( void  )

Get the size of the frame buffer in pixels.

Returns
The current size of the frame buffer in pixels.

◆ setSize()

void rune::FrameBuffer::setSize ( rune::Vec2  newSize)

Set the size of the frame buffer in pixels.

Parameters
newSizeThe new size that should be used to create the frame buffer.

The documentation for this class was generated from the following files: