[MPlayer-dev-eng] RGB vs. BGR

D Richard Felker III dalias at aerifal.cx
Thu Jan 29 17:49:48 CET 2004


On Thu, Jan 29, 2004 at 09:02:07AM +0100, Alex Beregszaszi wrote:
> Hi,
> 
> > also maybe a BGRA32_ME/RGBA32_ME (BGRA order in machine endian / read
> > as int32_t)/...
> that's a good idea
> 
> > which is #defined to BGR/RGB depending upon WORDS_BIGENDIAN could be
> > added, it would simplify code which accesses RGB/BGR32 as int instead
> > of bytewise based on that we could also use RGB15/16_ME instead of
> > plain RGB15/16 it would be more consistant and harder to
> > missunderstand, and would allow us to cleanly add support for
> > byteswaped 15/16 bit formats in the future, IIRC 4xm on bigendian
> > would use such a format internally
> > 
> > for the A possition we could use IMGFMT_RGB|32 vs. IMGFMT_RGB|32|64 or
> > maybe add a IMGFMT_ARGB= 'ARBx' / IMGFMT_RGBA= 'RBAx' / ...
> Maybe we should finally implement MID in G2 and drop the whole IMGFMT
> design :)

It's there in the (incomplete) G2 code I wrote, except I got rid of
the "MID" name because it was completely obfuscating and just called
it fmtdesc, with fmt as the normal variable/structmember name.

Rich




More information about the MPlayer-dev-eng mailing list