imlib and 24bit color, byte order

This is a little of topic, but, I am trying to make ImLib work 
with servers that only support pixmaps with 24 bits per pixel.
With my S3 Virge/VX and the XF86_SVGA server the byte ordering seems to be
backwards, basically, when masks are as follows:

r_mask = 0xff0000;
g_mask = 0x00ff00;
b_mask = 0x0000ff;

The colors come out as if the byte order were bgr.

I think this is because the server wants LSBFirst byte order, but the 24
bit render code puts it in MSBFirst. Looking
at the imlib render code, I think that there will be portability problems
with all color depths when the client is Little endian and the server
wants MSBFirst byte order, does anyone disagree?

Manish Vachharajani

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