[MPlayer-dev-eng] Defining MPlayers RGB color formats

Michael Niedermayer michaelni at gmx.at
Wed Aug 11 03:54:30 CEST 2004


Hi

On Monday 09 August 2004 16:51, Michael Niedermayer wrote:
> Hi
>
> On Monday 09 August 2004 15:58, Michael Niedermayer wrote:
> > Hi
> >
> > On Monday 09 August 2004 13:07, Reimar Döffinger wrote:
> > > Hi,
> > >
> > > > I think this question has already been answered in the thread
> > > > starting with:
> > > >
> > > > From: Michael Niedermayer <michaelni at gmx.at>
> > > > To: mplayer-dev-eng at mplayer.dev.hu
> > > > Date: Wed, 21 Jan 2004 16:47:56 +0100
> > > > Subject: [MPlayer-dev-eng] RGB vs. BGR
> > > > Message-Id: <200401211647.56307.michaelni at gmx.at>
> > >
> > > No, it wasn't answered because it is plain wrong.
> >
> > yes, alexs awnser was inconsistent and incomplete, and alex is away, the
> > technically best solution would be to ignore alex and make a
> > consistant&complete list which is as close as possible to the current
> > implementation, as i dont really see a different solution ill do that
>
> memory order:           old name 	new name
> RGBA                    		RGBA
> ARGB                    		ARGB
> BGRA                    		BGRA
> ABGR                    		ABGR
> RGB                     RGB24		RGB
> BGR                     BGR24		BGR
>
> order in an int         old name 	new name
> mostsignifant .. least significant bit
> 8A8R8G8B                BGR32		BGR32
> 8A8B8G8R                RGB32		RGB32
> 5R6G5B                  BGR16		BGR16
> 5B6G5R                  RGB16		RGB16
> 1A5R5G5B                BGR15		BGR15
> 1A5B5G5R                RGB15		RGB15
> 3R3G2B                  BGR8		BGR8
> 2B3G3R                  RGB8		RGB8
> 1R2G1B                  BG4R		BGR4_CHAR
> 1B2G1R                  RG4B		RGB4_CHAR
> 1R2G1B1R2G1B            BGR4		BGR4
> 1B2G1R1B2G1R            RGB4		RGB4
>
> RGB/BGR with a number means in register ordering, without a number it means
> in memory ordering, in the later case the number is unneeded as each letter
> always represents 8bits, this would even work with 16bit per component
> (RRGGBB)
> depending upon little vs big endian different in memory & in register
> formats will be equal (LE -> BGRA == BGR32 / BE -> ARGB == BGR32)
>
> if there are no better suggestions and no one against then ill update
> img_format.*
done, except IMGFMT_RGB / IMGFMT_BGR, these are already used so we have to 
keep RGB24/BGR24 for now

[...]
-- 
Michael
level[i]= get_vlc(); i+=get_vlc();		(violates patent EP0266049)
median(mv[y-1][x], mv[y][x-1], mv[y+1][x+1]);	(violates patent #5,905,535)
buf[i]= qp - buf[i-1];				(violates patent #?)
for more examples, see http://mplayerhq.hu/~michael/patent.html
stop it, see http://petition.eurolinux.org & http://petition.ffii.org/eubsa/en




More information about the MPlayer-dev-eng mailing list