GRASS GIS 8 Programmer's Manual
8.5.0dev(2024)-f63024f571
|
Raster Library - Get color rules. More...
Go to the source code of this file.
Functions | |
int | Rast_colors_count (const struct Colors *colors) |
Get both modular and fixed rules count. More... | |
int | Rast_get_fp_color_rule (DCELL *val1, unsigned char *r1, unsigned char *g1, unsigned char *b1, DCELL *val2, unsigned char *r2, unsigned char *g2, unsigned char *b2, const struct Colors *colors, int rule) |
Get color rule from both modular and fixed rules. More... | |
Raster Library - Get color rules.
(C) 2001-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 color_rule_get.c.
int Rast_colors_count | ( | const struct Colors * | colors | ) |
Get both modular and fixed rules count.
colors | pointer to color table structure |
Definition at line 24 of file color_rule_get.c.
int Rast_get_fp_color_rule | ( | DCELL * | val1, |
unsigned char * | r1, | ||
unsigned char * | g1, | ||
unsigned char * | b1, | ||
DCELL * | val2, | ||
unsigned char * | r2, | ||
unsigned char * | g2, | ||
unsigned char * | b2, | ||
const struct Colors * | colors, | ||
int | rule | ||
) |
Get color rule from both modular and fixed rules.
Rules are returned in the order as stored in the table (i.e. unexpected, high values first)
val1 | color value | |
[out] | r1,g1,b1 | color value |
val2 | color value | |
[out] | r2,g2,b2 | color value |
colors | pointer to color table structure | |
rule | rule index from 0 to G_color_count()-1 |
Definition at line 66 of file color_rule_get.c.