color_map

Global pointer to the color mapping table.

Description

extern COLOR_MAP *color_map;
Global pointer to the color mapping table. You must allocate your own COLOR_MAP either statically or dynamically and set color_map to it before using any translucent or lit drawing functions in a 256-color video mode! Example:
      color_map = malloc(sizeof(COLOR_MAP));
      if (!color_map)
	 abort_on_error("Not enough memory for color map!");
Examples using this:

Related Discussions

The following threads each have code containing this keyword: Note: You can click on the numbers to jump directly to the posts that reference this page.

Related Projects

The following projects include source code containing this keyword: