diff options
author | Ole Loots <ole@monochrom.net> | 2013-12-21 02:00:39 +0100 |
---|---|---|
committer | Ole Loots <ole@monochrom.net> | 2013-12-21 02:00:39 +0100 |
commit | 4abe5273c993520464b84523715b39d648ecf2d7 (patch) | |
tree | 849908665f9d4341e78e6957ed6a328ee86ae9ae /atari | |
parent | ae0f5834c448b108acd19e58ee9b286c1191482f (diff) | |
download | netsurf-4abe5273c993520464b84523715b39d648ecf2d7.tar.gz netsurf-4abe5273c993520464b84523715b39d648ecf2d7.tar.bz2 |
Added comments to plot API
Diffstat (limited to 'atari')
-rwxr-xr-x | atari/plot/plot.c | 26 |
1 files changed, 24 insertions, 2 deletions
diff --git a/atari/plot/plot.c b/atari/plot/plot.c index b82aa367c..d50922eba 100755 --- a/atari/plot/plot.c +++ b/atari/plot/plot.c @@ -996,6 +996,17 @@ inline static bool ablend_bitmap( struct bitmap * img, struct bitmap * bg, #ifdef WITH_8BPP_SUPPORT +/** + * Convert an bitmap to an 8 bit device dependant MFDB + * \param img the bitmap (only tested with 32bit bitmaps) + * \param x screen coord of the background + * \param y screen coord of the background + * \param clip the region of the image that get's converted + * \param bg the background used for cheap transparency + * \param flags + * \param out receives the converted bitmap (still owned by the plot API) + * + */ static bool bitmap_convert_8(struct bitmap * img, int x, int y, GRECT * clip, uint32_t bg, uint32_t flags, MFDB *out ) @@ -1112,7 +1123,7 @@ static bool bitmap_convert_8(struct bitmap * img, int x, stdform.fd_r1 = stdform.fd_r2 = stdform.fd_r3 = 0; int img_stride = bitmap_get_rowstride(img); - uint32_t prev_pixel = 0x12345678; + uint32_t prev_pixel = 0x12345678; //TODO: check for collision in first pixel unsigned long col = 0; unsigned char val = 0; uint32_t * row; @@ -1868,6 +1879,13 @@ static bool plot_polygon(const int *p, unsigned int n, return ( true ); } +/*** + * Set plot origin and canvas size + * \param x the x origin + * \param y the y origin + * \param w the width of the plot area + * \param h the height of the plot area + */ bool plot_set_dimensions(int x, int y, int w, int h) { bool doupdate = false; @@ -1893,9 +1911,13 @@ bool plot_set_dimensions(int x, int y, int w, int h) return(true); } +/*** + * Get current canvas size + * \param dst the GRECT * which receives the canvas size + * + */ bool plot_get_dimensions(GRECT *dst) { - dst->g_x = view.x; dst->g_y = view.y; dst->g_w = view.w; |