PicoVGA  1.0-cmake
VGA/TV display on Raspberry Pico
canvas.h File Reference

File Description

Canvas.

Author
Miroslav Nemecek Panda.nosp@m.38@s.nosp@m.eznam.nosp@m..cz
See also
Canvas
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Data Structures

struct  sCanvas
 Canvas descriptor. More...
 

Macros

#define DRAW_HWINTER   1
 
#define CANVAS_8   0
 8-bit pixels
 
#define CANVAS_4   1
 4-bit pixels
 
#define CANVAS_2   2
 2-bit pixels
 
#define CANVAS_1   3
 
#define CANVAS_PLANE2   4
 4 colors on 2 planes
 
#define CANVAS_ATTRIB8   5
 

Enumerations

enum  {
  DRAWIMG_WRAP, DRAWIMG_NOBORDER, DRAWIMG_CLAMP, DRAWING_COLOR,
  DRAWIMG_TRANSP, DRAWIMG_PERSP
}
 DrawImgMat mode. More...
 

Functions

void DrawRect (sCanvas *canvas, int x, int y, int w, int h, u8 col)
 Draw rectangle. More...
 
void DrawFrame (sCanvas *canvas, int x, int y, int w, int h, u8 col)
 Draw frame of 1 pixel thickness. More...
 
void DrawClear (sCanvas *canvas)
 Clear canvas (fill with black color) More...
 
void DrawPoint (sCanvas *canvas, int x, int y, u8 col)
 Draw a pixel. More...
 
void DrawLine (sCanvas *canvas, int x1, int y1, int x2, int y2, u8 col)
 Draw a line. More...
 
void DrawFillCircle (sCanvas *canvas, int x0, int y0, int r, u8 col, u8 mask=0xff)
 Draw filled circle. More...
 
void DrawCircle (sCanvas *canvas, int x0, int y0, int r, u8 col, u8 mask=0xff)
 Draw circle. More...
 
void DrawText (sCanvas *canvas, const char *text, int x, int y, u8 col, const void *font, int fontheight=8, int scalex=1, int scaley=1)
 Draw text (transparent background) More...
 
void DrawTextBg (sCanvas *canvas, const char *text, int x, int y, u8 col, u8 bgcol, const void *font, int fontheight=8, int scalex=1, int scaley=1)
 Draw text with background color. More...
 
void DrawImg (sCanvas *canvas, sCanvas *src, int xd, int yd, int xs, int ys, int w, int h)
 Draw image (without transparency) More...
 
void DrawBlit (sCanvas *canvas, sCanvas *src, int xd, int yd, int xs, int ys, int w, int h, u8 col)
 Draw image with transparency. More...
 
void DrawImgMat (sCanvas *canvas, const sCanvas *src, int x, int y, int w, int h, const class cMat2Df *m, u8 mode, u8 color)
 Draw 8-bit image with 2D transformation matrix. More...
 
void DrawTileMap (sCanvas *canvas, const sCanvas *src, const u8 *map, int mapwbits, int maphbits, int tilebits, int x, int y, int w, int h, const cMat2Df *mat, u8 horizon)
 Draw tile map using perspective projection. More...
 
void DrawImgLine (sCanvas *canvas, sCanvas *src, int xd, int yd, int xs, int ys, int wd, int ws)
 Draw image line interpolated. More...