|
| MetalRenderer () |
|
| ~MetalRenderer () override |
|
void | initialize () override |
| Initialize the renderer and its resources. More...
|
|
void | clear (glm::vec4) override |
| Clear the screen to the given color. More...
|
|
void | present () override |
| Swap buffers to present the rendered frame. More...
|
|
void | resize_viewport (int, int) override |
| Resize the rendering context. More...
|
|
void | set_context (const void *) override |
| Set the platform-specific rendering context. More...
|
|
void * | get_context () override |
| Get the platform-specific rendering context. More...
|
|
void | destroy () override |
| Destroy rendering resources. More...
|
|
bool | load_font (const std::string &, const std::string &, int) override |
| Load a font. More...
|
|
std::shared_ptr< Texture > | load_texture (const std::string &) override |
| Load a texture from disk. More...
|
|
std::shared_ptr< Texture > | get_texture (const std::string &) override |
| Get a previously loaded texture. More...
|
|
void | unload_font (const Font &) override |
| Unload a loaded font. More...
|
|
void | unload_texture (Uint32) override |
| Unload a texture by its ID. More...
|
|
void | draw_texture (const Texture *texture, const Rect2 &dest_rect, float rotation, const glm::vec4 &color, const Rect2 &src_rect, int z_index, bool flip_h, bool flip_v, const UberShader &uber_shader) override |
| Draw a textured quad. More...
|
|
void | draw_rect (Rect2, float, const glm::vec4 &, bool, int) override |
| Draw a rectangle (filled or outlined). More...
|
|
void | draw_text (const std::string &, float, float, float, float, const glm::vec4 &, const std::string &, int, const UberShader &, int) override |
| Draw text to screen. More...
|
|
void | draw_line (float, float, float, float, float, float, const glm::vec4 &, int) override |
| Draw a line. More...
|
|
void | draw_triangle (float, float, float, float, float, float, float, const glm::vec4 &, bool, int) override |
| Draw a triangle. More...
|
|
void | draw_circle (float, float, float, float, const glm::vec4 &, bool, int, int) override |
| Draw a circle. More...
|
|
void | draw_polygon (const std::vector< glm::vec2 > &, float, const glm::vec4 &, bool, int) override |
| Draw a polygon. More...
|
|
void | flush () override |
| Submit all batched draw calls. More...
|
|
virtual | ~Renderer ()=default |
|
void | set_view_matrix (const glm::mat4 &view_matrix=glm::mat4(1.f)) |
|
glm::mat4 | get_view_matrix () const |
|
virtual Uint32 | get_framebuffer_texture () const |
|
virtual HashMap< std::string, std::shared_ptr< Texture > > & | get_loaded_textures () |
|
virtual std::vector< std::string > & | get_loaded_fonts_name () |
|
|
void | set_default_font (const std::string &) override |
| Set the current font to use for rendering. More...
|
|
void | render_fbo () override |
| Render the current frame buffer. More...
|
|
void | set_effect_uniforms (const UberShader &, const glm::vec2 &) override |
|
glm::vec2 | get_texture_size (Uint32) const override |
|
glm::vec2 | rotate_point (const glm::vec2 &point, const glm::vec2 ¢er, float radians) |
| Rotate a point around a center point. More...
|
|
Recti | calc_display () |
| Calculate the display rectangle for rendering based on the viewport and window size. More...
|
|
void | submit (const BatchKey &key, float x, float y, float w, float h, float u0, float v0, float u1, float v1, const glm::vec4 &color, float rotation=0.0f, bool is_filled=true) |
| Add a quad (textured or untextured) to the appropriate batch. More...
|
|