blaze
|
Immediate drawing. More...
Functions | |
BLZAPIENTRY int BLZAPICALL | BLZ_DrawImmediate (struct BLZ_Texture *texture, struct BLZ_Vector2 position, struct BLZ_Rectangle *srcRectangle, float rotation, struct BLZ_Vector2 *origin, struct BLZ_Vector2 *scale, struct BLZ_Vector4 color, enum BLZ_SpriteFlip effects) |
Immediately draws a sprite using the specified parameters to screen. More... | |
BLZAPIENTRY int BLZAPICALL | BLZ_LowerDrawImmediate (GLuint texture, struct BLZ_SpriteQuad *quad) |
Lower level immediate drawing function, called by BLZ_DrawImmediate. More... | |
Immediate drawing.
BLZAPIENTRY int BLZAPICALL BLZ_DrawImmediate | ( | struct BLZ_Texture * | texture, |
struct BLZ_Vector2 | position, | ||
struct BLZ_Rectangle * | srcRectangle, | ||
float | rotation, | ||
struct BLZ_Vector2 * | origin, | ||
struct BLZ_Vector2 * | scale, | ||
struct BLZ_Vector4 | color, | ||
enum BLZ_SpriteFlip | effects | ||
) |
Immediately draws a sprite using the specified parameters to screen.
texture | The texture to draw |
position | Position of the sprite (top-left corner if origin is NULL) |
srcRectangle | Part of the source texture to draw defined in pixels, or NULL if the whole texture should be drawn |
rotation | Rotation of the sprite in clockwise direction in radians |
origin | The point around which the sprite should be positioned and rotated, if NULL, top-left corner (0, 0) will be used |
scale | Scale in X and Y directions, if NULL, defaults to (1,1) |
color | Color to apply to the sprite (color gets multiplied if default shader is used) |
effects | Defines if the sprite should be flipped in any direction |
BLZAPIENTRY int BLZAPICALL BLZ_LowerDrawImmediate | ( | GLuint | texture, |
struct BLZ_SpriteQuad * | quad | ||
) |
Lower level immediate drawing function, called by BLZ_DrawImmediate.
Use it if you have a predefined quad to draw (like a fullscreen one for post-processing effects, for example).