Struct cuivre::graphics::GraphicsManager[][src]

pub struct GraphicsManager { /* fields omitted */ }

Manages everything related to graphics and rendering.

Methods

impl GraphicsManager
[src]

Initializes graphics from SDL object, resource loader, default shader paths and window settings

Get the current window's size.

Sets the OpenGL viewport. Call when the window is resized.

Draws a Sprite on a textured quad mesh.

transform specifies the position, scale, and rotation of the drawn Sprite.

Camera is the camera the Sprite is viewed from.

Note: by default all sprites are square. For non-square sprites, you must use transform.scale to scale the quad appropriately.

Draws a string.

Adds a drawcall to the render queue.

If no suitable batch is found, a new one is created.

Renders the current queued batches.

Auto Trait Implementations