[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: 'nother XLib Question



++ Hours.

Forget XYPixmap. It's slower anyway. Let's stick to the nice ZPixmap.

The data passed to XCreateImage has to be in a specific format depending on
the bpp used in the display.
The data is RGB clumped, but the exact format of the 2 bytes forming the RGB
triplet is strange. For 16bpp it appears to have the format:
NNNRRRNNNBBBNNGGG, where N is an undefined pixel values that does not affect
the outcome in the least. Changing this to 24 bpp results in the format
NNNRRRNNNBBBBNNGGG NNNNNNNN.

This sucks.

Can anyone, either tell me, or tell me how to find: how to figure out the
correct way to format the data to pass to XCreateImage when the bpp is a)
16, b) 32, c) Arbitrary.

Thanks,
Doug.


---------------------------------------------------------------------
To unsubscribe, e-mail: linuxgames-unsubscribe@sunsite.dk
For additional commands, e-mail: linuxgames-help@sunsite.dk