Mail Archives: djgpp/1997/01/25/22:49:43
On 25 Jan 1997 22:25:01 GMT "Gautam N. Lad" <gautam AT interlog DOT com> writes:
>Hi,
>Ok, since I don't know how to display PCX images, I had to resort
>to Allegro (which I think is amazing, and I look forward to the
>new version which includes some 3D goodies!!).
>
>I modified the example EX15.C source to display two different PCXs.
>So, here's the code. Now what I don't understand is why
>does Allegro use one palette to display an image, and when another
>palette is created for another image, that original palette
>gets screwed up, and starts using the palette from the new palette.
>Are ya confused? Look at the source; it might be easier.
>
>In this program, two PCX images are loaded (I could've used a for
>loop, but I wanted to make sure it works. Oh well.)
Of course it uses the new palette - you called setpalette on the new
palette.
You only have 256 colors to use, and when you change them, _everything_
on the screen uses the new 256 colors.
...Chambers
- Raw text -