GRASS GIS 8 Programmer's Manual
8.5.0dev(2024)-d6dec75dd4
|
Raster Library - Get raster row (colors) More...
Go to the source code of this file.
Functions | |
void | Rast_get_row_colors (int fd, int row, struct Colors *colors, unsigned char *red, unsigned char *grn, unsigned char *blu, unsigned char *nul) |
Reads a row of raster data and converts it to RGB. More... | |
Raster Library - Get raster row (colors)
(C) 1999-2009 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 get_row_colr.c.
void Rast_get_row_colors | ( | int | fd, |
int | row, | ||
struct Colors * | colors, | ||
unsigned char * | red, | ||
unsigned char * | grn, | ||
unsigned char * | blu, | ||
unsigned char * | nul | ||
) |
Reads a row of raster data and converts it to RGB.
Reads a row of raster data and converts it to red, green and blue components according to the colors parameter. This provides a convenient way to treat a raster layer as a color image without having to explicitly cater for each of CELL
, FCELL
and DCELL
types.
fd | field descriptor | |
row | row number | |
colors | pointer to Colors structure which holds color info | |
[out] | red | red value |
[out] | grn | green value |
[out] | blu | blue value |
[out] | nul | null value |
Definition at line 39 of file get_row_colr.c.