6 #include <grass/raster.h> 7 #include <grass/glocale.h> 9 #define MAX_COLORS 1024 40 if (count > max - min + 1)
41 count = max - min + 1;
43 for (n = 1; n <=
count; n++) {
48 &n, red, grn, blu, colors);
int Rast_add_modular_c_color_rule(const CELL *val1, int r1, int g1, int b1, const CELL *val2, int r2, int g2, int b2, struct Colors *colors)
Add modular integer color rule (CELL version)
void Rast_init_colors(struct Colors *colors)
Initialize color structure.
void G_fatal_error(const char *msg,...)
Print a fatal error message to stderr.
long G_lrand48(void)
Generate an integer in the range [0, 2^31)
void Rast_set_c_color_range(CELL min, CELL max, struct Colors *colors)
Set color range (CELL version)
long G_srand48_auto(void)
Seed the pseudo-random number generator from the time and PID.
void Rast_make_random_colors(struct Colors *colors, CELL min, CELL max)
make random colors