wrong colours from scrsave
dave hally
hally at SCYLLA.DREA.DND.CA
Fri Feb 1 00:34:47 AEST 1991
The following small program makes a 101 x 101 window, clears it to
white, and saves it in the file white.img. It works correctly.
#include <gl.h>
main()
{ prefposition(500,600,500,600);
winopen("mytest");
RGBmode();
/* doublebuffer(); */
gconfig();
cpack(0xffffff);
clear();
/* swapbuffers(); */
system("scrsave white.img 500 600 500 600");
}
When the comment delimiters are removed so that double buffering is in
force, the display on the screen is exactly the same, but now in the file,
every pixel has the colour value f0f0f0 (very light gray) instead of
ffffff (white). What is going on?
If the colour map is used instead of RGBmode, it works correctly both
with and without double buffering.
(BTW: I have a 4D/20 running 3.3.1)
Dave
More information about the Comp.sys.sgi
mailing list