3#include <meteorutils/rect.h>
5#include <rendering/rendercommand.h>
53 inline void useSourceRect(
bool useSrcRect) { this->useSrcRect = useSrcRect; }
RenderCommand are responsible for rendering visuals to the screen.
Definition rendercommand.h:10
This a RenderCommand that draws an image on to the screen.
Definition texrendercmd.h:11
MTexRenderCmd(ERenderLayer layer, uint8_t sortingOrder)
Constructor.
void useSourceRect(bool useSrcRect)
Set to true if a part of the texture needs to be rendererd.
Definition texrendercmd.h:53
void updateSrcRect(SRect rect)
Update the Rect for image. Src Rect is the rect used for rendering specific parts of the texture.
Definition texrendercmd.h:33
void updateRect(SRect rect)
Update the Rect for rendering.
Definition texrendercmd.h:27
void updatePivot(SVector2 pivot)
Update the pivot of image during render.
Definition texrendercmd.h:43
void render() override
Renders the image to screen.
void bindTexture(MTexture *tex)
Bind a texture to draw.
void updateRotation(float rotation)
Update rotation of the img during render.
Definition texrendercmd.h:48
void updateScale(SVector2 scale)
Update the scale of image during render.
Definition texrendercmd.h:38
This class holds an image that can be rendererd to the screen.
Definition texture.h:12
A struct representing rectangle.
Definition rect.h:8
A structure representing a 2D Vector.
Definition vector2d.h:11