create_color_table man page on DragonFly

Man page or keyword search:  
man Server   44335 pages
apropos Keyword Search (all sections)
Output format
DragonFly logo
[printable version]

create_color_table(3)		Allegro manual		 create_color_table(3)

NAME
       create_color_table  -  Fills  a	color  mapping	table  for  customised
       effects. Allegro game programming library.

SYNOPSIS
       #include <allegro.h>

       void  create_color_table(COLOR_MAP  *table,  const  PALETTE  pal,  void
       (*blend)(PALETTE	 pal,  int  x,	int y, RGB *rgb), void (*callback)(int
       pos));

DESCRIPTION
       Fills the specified color mapping table with lookup data for doing cus‐
       tomised	effects with the specified palette, calling the blend function
       to determine the results of each color combination.

       Your blend routine will be passed a pointer to the palette and the  two
       indices	of the colors which are to be combined, and should fill in the
       RGB structure with the desired result in 0-63 format. Allegro will then
       search  the  palette  for  the  closest match to the RGB color that you
       requested, so it doesn't matter if the palette has no exact  match  for
       this color.

       If  the callback function is not NULL, it will be called 256 times dur‐
       ing the calculation, allowing you  to  display  a  progress  indicator.
       Example:

	  COLOR_MAP greyscale_table;
	  ...
	  void return_grey_color(const PALETTE pal,
				 int x, int y, RGB *rgb)
	  {
	     ...
	  }
	  ...
	     /* Build a color lookup table for greyscale effect. */
	     create_color_table(&greyscale_table, pal,
				return_grey_color, NULL);

SEE ALSO
       color_map(3),	create_light_table(3),	 create_trans_table(3),	  cre‐
       ate_blender_table(3),	 draw_trans_sprite(3),	   draw_lit_sprite(3),
       draw_gouraud_sprite(3), rgb_map(3), excolmap(3)

Allegro				 version 4.4.2		 create_color_table(3)
[top]

List of man pages available for DragonFly

Copyright (c) for man pages and the logo by the respective OS vendor.

For those who want to learn more, the polarhome community provides shell access and support.

[legal] [privacy] [GNU] [policy] [cookies] [netiquette] [sponsors] [FAQ]
Tweet
Polarhome, production since 1999.
Member of Polarhome portal.
Based on Fawad Halim's script.
....................................................................
Vote for polarhome
Free Shell Accounts :: the biggest list on the net