| special functions |
void xxx_blit(fb_data *data, int x, int block_y, int width, int block_height, int stride) |
1) |
1) |
|
Special high-performance function to move external bitmap data (native lcd bitmap format) directly into the lcd. |
void xxx_update() |
|
|
|
Update lcd contents with contents of the whole framebuffer. |
void xxx_update_rect(int x, int y, int width, int height) |
|
|
|
Update a rectangular area of the lcd contents with the corresponding area of the framebuffer. The boundaries (horizontal or vertical depending on the hardware) of the update area are adjusted to block boundaries, i.e. the function always updates whole blocks. |
void xxx_clear_display() |
|
2) |
|
Clear the whole framebuffer, i.e. set all pixels to the current background colour (white for b&w) or to the current foreground colour (black for b&w) if inversevid is on. |
| parameter handling |
void xxx_set_drawmode(int mode) |
|
|
|
Set draw mode for subsequent drawing operations (inverse / foreground / background / solid + inversevid flag). Foreground and background are fixed to black & white for b&w graphics. |
int xxx_get_drawmode() |
|
|
|
Return current draw mode. |
void xxx_set_foreground(unsigned foreground) |
|
|
|
Set the foreground brightness (0..MAX_LEVEL) / colour (packed RGB value) for subsequent drawing operations. |
unsigned xxx_get_foreground() |
|
|
|
Return current foreground brightness (0..MAX_LEVEL) / colour (packed RGB value). |
void xxx_set_background(unsigned background) |
|
|
|
Set the background brightness (0..MAX_LEVEL) / colour (packed RGB value) for subsequent drawing operations. |
unsigned xxx_get_background() |
|
|
|
Return current background brightness (0..MAX_LEVEL) / colour (packed RGB value). |
void xxx_set_drawinfo(int mode, unsigned foreground, unsigned background) |
|
|
|
Set draw mode, foreground and background brightness / colour at once. |
| pixel functions |
void xxx_drawpixel(int x, int y) |
|
|
|
Draw a pixel using current draw mode & foreground colour. |
| lines and line-like primitives |
void xxx_drawline(int x1, int y1, int x2, int y2) |
|
|
|
Draw a line using current draw mode & foreground colour, using the bresenham algorithm. |
void xxx_hline(int x1, int x2, int y) |
|
|
|
Draw a horizontal line using current draw mode & foreground colour. At least a bit faster than using bresenham, possibly using further optimisation. |
void xxx_vline(int x, int y1, int y2) |
|
|
|
Draw a vertical line using current draw mode & foreground colour. At least a bit faster than using bresenham, possibly using further optimisation. |
void xxx_drawrect(int x, int y, int width, int height) |
|
|
|
Draw a rectangle (frame) using current draw mode & foreground colour. |
| filled primitives |
void xxx_fillrect(int x, int y, int width, int height) |
|
|
|
Fill a rectangular area with foreground pixels. |
void xxx_filltriangle(int x1, int y1, int x2, int y2, int x3, int y3) |
3) |
3) |
3) |
Fill a triangular area with foreground pixels. Useful for 3-d rendering. |
| bitmaps and text |
void xxx_bitmap_part(fb_data *data, int src_x, int src_y, int stride, int x, int y, int width, int height) |
|
4) |
|
Draw a partial native bitmap. For b&w, this uses the current draw mode. The stride parameter is the width of the source bitmap in pixels. |
void xxx_bitmap(fb_data *data, int x, int y, int width, int height) |
|
4) |
|
Draw a native bitmap. For b&w, this uses the current draw mode. |
void xxx_mono_bitmap_part(unsigned char *data, int src_x, int src_y, int stride, int x, int y, int width, int height) |
|
|
|
Draw a partial monochrome (1-bit) bitmap. This uses the current draw mode, foreground and background colour. For monochrome displays this function is simply an alias to xxx_bitmap_part() and hence uses the same bitmap format. For greyscale and colour displays the format should be similar to the respective native format, i.e. for iriver H1xx, where the native format consists of vertical 4-pixel blocks (2bpp), the monochrome format consists of vertical 8-pixel blocks (same as the native archos recorder/ Ondio and native iriver H1X0? remote format). |
void xxx_mono_bitmap(unsigned char *data, int x, int y, int width, int height) |
|
|
|
Draw a monochrome (1-bit) bitmap. This uses the current draw mode, foreground and background colour. |
void xxx_gray_bitmap_part(unsigned char *data, int src_x, int src_y, int stride, int x, int y, int width, int height) |
|
2)3) |
3) |
Draw a partial greyscale bitmap. This uses the canonical greyscale format, 1 byte/pixel. |
void xxx_gray_bitmap(unsigned char *data, int x, int y, int width, int height) |
|
2)3) |
3) |
Draw a greyscale bitmap. This uses the canonical greyscale format, 1 byte/pixel. |
void xxx_color_bitmap_part(unsigned char *data, int src_x, int src_y, int stride, int x, int y, int width, int height) |
|
|
3) |
Draw a partial true colour bitmap. This uses the canonical true colour format, 3 byte/pixel RGB. |
void xxx_color_bitmap(unsigned char *data, int x, int y, int width, int height) |
|
|
3) |
Draw a true colour bitmap. This uses the canonical true colour format, 3 byte/pixel RGB. |
void xxx_putsxyofs(int x, int y, int offset, char *string) |
|
|
|
Draw the string, but leave out the 'offset' left pixel columns, clipping the text. Uses the current draw mode, foreground and background colour. |
void xxx_putsxy(int x, int y, char *string) |
|
|
|
Draw the string, using the current draw mode, foreground and background colour. |
| scrolling |
void xxx_scroll_left(int count) |
3) |
2)3) |
3) |
Scroll display contents left by 'count' pixels. Scrolled in pixels at the right are always white. |
void xxx_scroll_right(int count) |
3) |
2)3) |
3) |
Scroll display contents right by 'count' pixels. Scrolled in pixels at the left are always white. |
void xxx_scroll_up(int count) |
3) |
2)3) |
3) |
Scroll display contents up by 'count' pixels. Scrolled in pixels at the bottom are always white. |
void xxx_scroll_down(int count) |
3) |
2)3) |
3) |
Scroll display contents down by 'count' pixels. Scrolled in pixels at the top are always white |