#Color Cycleing
24-Dec-94 16:35:00
Sb: #44875-#Color Cycleing
Fm: Werner Kazmierzak 100041,1320
To: Gary Chaney 74347,2625
Gary,
why fiddling around with colormaps ? Just read the current values with
GetRGB4() and push them in a rotating manner into a colortable, then call
LoadRGB4(). Thats all.
You cannot directly move around colors in colormaps, because they are
hardware specific structures and you should not count on them to be
anything you can understand. You only may use SetRGB4CM() to set colors in
a colormap before it is linked to a viewport. Beginning with OS 2.0, first
of all, you must tell the colormap about the viewport it will be linked to
using VideoControl(). After all, you can link it into the ViewPort and
call MakeVPort() to display the new colors. So, if you let your display
being set up by intuition, best thing is leaving the colormaps untouched.
SetRGB4() and LoadRGB4() only work with the colormap already attached to
the viewport (in your case intuition has done this for you), and will
refresh the colors automagically.
– wkc – … via AP from Hamburg, Germany