On Tue, 5 Mar 2002, Cedric PEROTTO wrote:

>  I'm trying to create overlay planes in Direct Color. I first tried with
> XAllocColorCells but I wasn't able to allocate more than 256 cells.

 I assume you don't mean overlays in the conventional sense where windows
go into a particular layer, but rather planar "overlays" where a single
window can have many planes distinguishable by a plane mask.

   There are only 256 cells in depth 24 DirectColor visuals so
you can't allocate more than 256 cells.

>   After I tried the XAllocColorPlanes function, the allocation is OK for
> more than 256 cells. But I encountered problems when I wanted to store
> my color cells : I couldn't store any colors when I had more than one
> plan in a given color(I don't know how to use the red,green or blue mask
> when you have more than one red, green or blue plane ).
> Moreover, when I draw something in my planes the colors used aren't
> always the ones I stored in my colorplane.
> Could someone give me some help about XAllocColorPlanes? Or another
> solution in order to use overlay planes with more than 256 cells?

    There will never be more than 256 cells on PC hardware, in any
visual, in any depth.  PC hardware just doesn't support that kind
of stuff.  If you want 4096 cells you need to be on expensive SGI
hardware.  That's an expensive route to go for legacy features.
You should probably be looking for ways to be working in TrueColor
as your task will only get harder in the future - indexed modes are
going the way of the dodo.


                                Mark.

_______________________________________________
Xpert mailing list
[EMAIL PROTECTED]
http://XFree86.Org/mailman/listinfo/xpert

Reply via email to