![]() |
CUGL 3.0
Cornell University Game Library
|
#include <CUTextureRenderer.h>
Public Member Functions | |
void | draw (const std::shared_ptr< Texture > &texture) |
bool | init () |
Static Public Member Functions | |
static std::shared_ptr< TextureRenderer > | alloc () |
A class for drawing a full-screen texture.
This class is an alternative to SpriteBatch
for the case when all you want to do is draw a single texture as a full-screen quad. There is no support for compositing or other features. It is primarily used to test out custom shaders.
|
inlinestatic |
Returns a new texture renderer with the default vertex capacity
void cugl::graphics::TextureRenderer::draw | ( | const std::shared_ptr< Texture > & | texture | ) |
Draws a full screen quad given a texture
texture | The texture to draw |
bool cugl::graphics::TextureRenderer::init | ( | ) |
Initializes a texture renderer.