[gst-devel] OR'ed capabilities

Christian Fredrik Kalager Schaller uraeus at gnome.org
Sun Feb 1 15:00:00 CET 2004


Hi Jan (and the rest of the gang :)
Would be much better if everytime a mail cause us to explain something
we add it to the relevant doc (PWG in this case I assume) and just point
to the doc in our mail. Would probably make our docs much better and
much more powerful quickly :)

And yes I know that talk is cheap :)

Christian

On Sun, 2004-02-01 at 22:08, Jan Schmidt wrote:
> On Mon, 2004-02-02 at 02:37, Martin Soto wrote:
> > Hi!
> > 
> > The DVD demuxer audio sources, need to be able to handle different types
> > of audio, namely, MPEG, AC3, DTS and linear PCM.  Since a single pad may
> > have to change dynamically between two or more of these types, I need to
> > define the pad template for such a pad as a boolean OR of the caps for
> > the four possible types.
> > 
> > How do I do that?  As far as I can see, static caps aren't able to
> > express such a thing.  An example would come really handy.
> > 
> 
> Hi Martin,
> 
> You want chained caps, as used in lots of places to do exactly this. For
> example, ffcolorspace has some caps like this (plus more):
> 
>       video/x-raw-yuv,
>         width=(int)[ 16, 4096 ],
>         height=(int)[ 16, 4096 ],
>         framerate=(double)[ 0, 1.7976931348623157e+308 ],
>         format=(fourcc)I420;
>       video/x-raw-yuv,
>         width=(int)[ 16, 4096 ]
>         height=(int)[ 16, 4096 ]
>         framerate=(double)[ 0, 1.7976931348623157e+308 ]
>         format=(fourcc)YUY2;
>       video/x-raw-rgb, 
>         width=(int)[ 16, 4096 ], 
>         height=(int)[ 16, 4096 ], 
>         framerate=(double)[ 0, 1.7976931348623157e+308 ],
>         bpp=(int)24,
>         depth=(int)24,
>         red_mask=(int)16711680,
>         green_mask=(int)65280,
>         blue_mask=(int)255,
>         endianness=(int)4321
> 
> This says that it can produce yuv I420, YUY2 or 24 bit RGB. The ; in a
> static caps string starts a chained capability.
> 
> J.





More information about the gstreamer-devel mailing list