Mail Archives: djgpp/1998/04/01/09:15:15
Ishpeck wrote:
>
> Yes, I could set the entire palette to the palette
> of the flic... but, I don't want to.
>
> Is there a way to change the palette of a bitmap
> in the memory?
>
> Say, for instance, I wanted to print two bitmaps
> simultaneously and each of them had a different
> palette... could I change the one, or the other
> so that the palette of one matched the other?
>
> Could I convert the palette of one bitmap before
> I printed it, so that it could match the palette
> of the other one?
>
> Or am I just hoping for things that cannot be?
>
> Charles Terry wrote:
> >
> > No the palette is set in the graphics driver
> > so if you change it the whole display changes
> > but you seem to be indicating that the rest of the
> > screen at this point is unused except for the textout-?
> >
> > I think you can use the grabber utility to get the
> > pallete from your flic and package both the flic and
> > pallete in a data file and load both at runtime
> >
> > Charles Terry
I'm sure what you want exists, all of the commercial graphics
packages have utilities for converting palletes. I don't know
about freeware, although I bet Shawn has some routines for that.
If you have to bo it youself you could by setting up
a routine to compare the two paletes and assigning a closest
match to each color then rewriting the memory bitmap.
In the paticular case your talking about though- wouldn't
converting the bitmap slow down the flic?
Charles
- Raw text -