[MPlayer-dev-eng] What is the format of 4bpp? (postproc/yuv2rgb

Arpi arpi at thot.banki.hu
Thu Jan 30 01:07:58 CET 2003


Hi,

> of being messy hack ...
> but if we have to choose simplicity+performance vs. nice code, i vote for
> the former. so take BGR7
> 
> we could also try things like ('BGR'<<8)|(8|128) (use the most sign. bit as
> a flag) but it may cause trouble for if(BGR_DEPTH(fmt)<24) type checks.
> hmm, maybe not, if we change BGR_DEPTH macro...

yes it's definitly a good idea :)

('BGR'<<8)|(4|128)
->
#define IMGFMT_RGB4  (IMGFMT_RGB|4)
#define IMGFMT_RG4B  (IMGFMT_RGB|4|128)
#define IMGFMT_RGB1  (IMGFMT_RGB|1)
#define IMGFMT_RG1B  (IMGFMT_RGB|1|128)

and change depth macros to:
#define IMGFMT_RGB_DEPTH(fmt) ((fmt)&0x3F)

so we saved bits 6 and 7 for special purposes.


A'rpi / Astral & ESP-team

--
Developer of MPlayer, the Movie Player for Linux - http://www.MPlayerHQ.hu
    "However, many people beg for its inclusion in Debian. Why?" - Gabucino
  "Because having new software in Debian is good." - Josselin Mouette
"Because having good software in Debian is new." - Gabucino


More information about the MPlayer-dev-eng mailing list