GRASS GIS 8 Programmer's Manual
8.5.0dev(2024)-602118adcc
|
Display Driver - draw raster data. More...
#include <stdio.h>
#include <stdlib.h>
#include <grass/gis.h>
#include <grass/raster.h>
#include <grass/display.h>
#include "driver.h"
Go to the source code of this file.
Functions | |
int | D_draw_raster (int A_row, const void *array, struct Colors *colors, RASTER_MAP_TYPE data_type) |
Draw raster row. More... | |
int | D_draw_d_raster (int A_row, const DCELL *darray, struct Colors *colors) |
Draw raster row (DCELL) More... | |
int | D_draw_f_raster (int A_row, const FCELL *farray, struct Colors *colors) |
Draw raster row (FCELL) More... | |
int | D_draw_c_raster (int A_row, const CELL *carray, struct Colors *colors) |
Draw raster row (CELL) More... | |
void | D_raster_draw_begin (void) |
Prepare for raster graphic. More... | |
int | D_draw_raster_RGB (int A_row, const void *r_raster, const void *g_raster, const void *b_raster, struct Colors *r_colors, struct Colors *g_colors, struct Colors *b_colors, RASTER_MAP_TYPE r_type, RASTER_MAP_TYPE g_type, RASTER_MAP_TYPE b_type) |
Draw raster row in RGB mode. More... | |
void | D_raster_draw_end (void) |
Finish raster rendering. More... | |
Variables | |
int | D__overlay_mode |
Display Driver - draw raster data.
(C) 2006-2011 by the GRASS Development Team
This program is free software under the GNU General Public License (>=v2). Read the file COPYING that comes with GRASS for details.
Definition in file display/raster.c.
Draw raster row (CELL)
The row gives the map array row. The carray array provides the categories for each raster value in that row. This routine is called consecutively with the information necessary to draw a raster image from north to south. No rows can be skipped. All screen pixel rows which represent the current map array row are rendered. The routine returns the map array row which is needed to draw the next screen pixel row.
A_row | row number (starts at 0) |
carray | data buffer |
colors | pointer to Colors structure |
Definition at line 104 of file display/raster.c.
Draw raster row (DCELL)
A_row | row number (starts at 0) |
darray | data buffer |
colors | pointer to Colors structure |
Definition at line 66 of file display/raster.c.
Draw raster row (FCELL)
A_row | row number (starts at 0) |
farray | data buffer |
colors | pointer to Colors structure |
Definition at line 81 of file display/raster.c.
int D_draw_raster | ( | int | A_row, |
const void * | array, | ||
struct Colors * | colors, | ||
RASTER_MAP_TYPE | data_type | ||
) |
Draw raster row.
Presumes the map is drawn from north to south.
If overlay mode is desired, then call D_set_overlay_mode() first.
A_row | row number (starts at 0) |
array | data buffer |
colors | pointer to Colors structure |
data_type | raster type (CELL, FCELL, DCELL) |
Definition at line 51 of file display/raster.c.
int D_draw_raster_RGB | ( | int | A_row, |
const void * | r_raster, | ||
const void * | g_raster, | ||
const void * | b_raster, | ||
struct Colors * | r_colors, | ||
struct Colors * | g_colors, | ||
struct Colors * | b_colors, | ||
RASTER_MAP_TYPE | r_type, | ||
RASTER_MAP_TYPE | g_type, | ||
RASTER_MAP_TYPE | b_type | ||
) |
Draw raster row in RGB mode.
A_row | row number (starts at 0) |
r_raster | red data buffer |
g_raster | green data buffer |
b_raster | blue data buffer |
r_colors | colors used for red channel |
g_colors | colors used for green channel |
b_colors | colors used for blue channel |
r_type | raster type used for red channel |
g_type | raster type used for red channel |
b_type | raster type used for red channel |
Definition at line 173 of file display/raster.c.
void D_raster_draw_begin | ( | void | ) |
Prepare for raster graphic.
The raster display subsystem establishes conversion parameters based on the screen extent defined by top, bottom, left, and right, all of which are obtainable from D_get_dst() for the current frame.
Definition at line 148 of file display/raster.c.
References COM_begin_raster(), D__overlay_mode, D_get_a(), D_get_d(), dst, and src.
void D_raster_draw_end | ( | void | ) |
Finish raster rendering.
Definition at line 225 of file display/raster.c.
References COM_end_raster().
|
extern |
Definition at line 35 of file raster2.c.
Referenced by D_raster_draw_begin(), and D_set_overlay_mode().