[gst-devel] RGB caps
rbultje at ronald.bitfreak.net
Tue Nov 25 08:05:25 CET 2003
On Tue, 2003-11-25 at 16:20, in7y118 at public.uni-hamburg.de wrote:
> - drop endianness. It's always G_BIG_ENDIAN.
> - drop depth. It's always depth == bpp.
Well, in ffmpeg. But not always (same as PCM int audio).
> - masks are always host-endian. To get the red part of a pixel, use code like
> this: red_part = pixel & GINT_TO_BE (red_mask);
I discussed this with Dave a few weeks ago. Masks are a nice thing, but
it doesn't work. We've tried, and we'll try again post-1.0. The current
proposal was to drop masks and only keep endianness. Nobody uses masks
except colorspace. all other elements are only extra complicated because
The proposal was to go back to endianness-derived RGB caps, where it's
either BE or LE. Broken (or weird) plugins that don't use
host-endianness but per-byte RGB reading (so the input RGB might have to
be BE, even on LE machines) can get that via colorspace, which can
convert from/to LE/BE on either machine.
That'd make RGB a lot easier to handle. Post-1.0 or so, we'll look at
this very interesting (but theoretical) situation where we've got RBG or
GBR or XHTRFBGHE instead of RGB_LE/BE. Currently, I don't care. It's
unused and too complicated.
Ronald Bultje <rbultje at ronald.bitfreak.net>
Linux Video/Multimedia developer
More information about the gstreamer-devel