Getting compor map colors.
Tim Hall
tjh at bucrf11.bu.edu
Thu Apr 25 00:45:08 AEST 1991
In article <1991Apr22.153229.7358 at cs.ruu.nl>, markov at cs.ruu.nl (Mark Overmars) writes:
|> I have the following problem. I want to draw colormap images inside a RGB
|> window. As a result I need to find out what the colors in the colormap are. To
|> this end I thought I should use the routine
|>
|> getmcolor()
|>
|> Unfortunately, this routine only work when you are in colormap mode, not when
|> you are in RGB mode. (Why?)
Dunno why, but you could always do somthing like......
current_window = winget(); /* Remember what the current window is */
noport(); /* Open a window that never appears */
color_window = winopen( NULL);
Read the color map here.
winclose( color_window );
if ( current_window > 0 ) /* >= ???? I forget.... */
winset( current_window );
Yuk, what a kludge.
|> Mark Overmars
--
-Tim Hall
tjh at bu-pub.bu.edu
The night is filled with the cries of dispossessed children in search
of paradise. -Dead Can Dance
More information about the Comp.sys.sgi
mailing list