[FFmpeg-devel] [PATCH] [2/??] [3/3] Filter graphs - Parser for a graph description

Michael Niedermayer michaelni
Fri Apr 18 18:28:09 CEST 2008


On Fri, Apr 18, 2008 at 05:35:40PM +0200, Vitor Sessak wrote:
> Hi
> 
> Michael Niedermayer wrote:
> > On Sat, Apr 12, 2008 at 04:40:24PM +0200, Vitor Sessak wrote:
> >> Hi
[...]
> > [...]
> >>         // We need to parse the inputs of the filter after we create it, so
> >>         // skip it by now
> >>         filters = skip_inouts(filters);
> >>
> >>         if(!(filter = parse_filter(&filters, graph, index, log_ctx)))
> >>             goto fail;
> >>
> >>         pad = parse_inouts(&inouts, &inout, chr == ',', LinkTypeIn, filter,
> >>                            log_ctx);
> > 
> > I do not like this design.
> 
> Me neither. But how else could I parse the following:
> 
> (in) (T1) picInPic, rotate, split (T2) (out) ; (T2) vflip (T1)
> 
> What will the parser do in the first "(T1)"? It don't have a pointer yet 
> to the AVFilterContext of the picInPic filter to store in the InOut 
> list. Nor does it have opened the vflip filter to make the link. Your 
> point about linking several filters is only valid for things like:


something approximately like: (in/out might not be hadled ideally)


 (in) (T1) picInPic, rotate, split (T2) (out) ; (T2) vflip (T1)
^
array:{"in",pIn}


 (in) (T1) picInPic, rotate, split (T2) (out) ; (T2) vflip (T1)
     ^
array:{"in",pIn}


 (in) (T1) picInPic, rotate, split (T2) (out) ; (T2) vflip (T1)
          ^
array:{"in",pIn}, {"T1",NULL}


 (in) (T1) picInPic, rotate, split (T2) (out) ; (T2) vflip (T1)
                   ^
array:{NULL, pPicInPicOut}                      openLinks:{"T1",pPicInPicIn}


 (in) (T1) picInPic, rotate, split (T2) (out) ; (T2) vflip (T1)
                           ^
array:{NULL, pRotateOut}                        openLinks:{"T1",pPicInPicIn}


 (in) (T1) picInPic, rotate, split (T2) (out) ; (T2) vflip (T1)
                                  ^
array:{NULL, pSplitOut1},{NULL, pSplitOut2}     openLinks:{"T1",pPicInPicIn}


 (in) (T1) picInPic, rotate, split (T2) (out) ; (T2) vflip (T1)
                                       ^
array:{NULL, pSplitOut2}                        openLinks:{"T1",pPicInPicIn}, {"T2", pSplitOut1}


 (in) (T1) picInPic, rotate, split (T2) (out) ; (T2) vflip (T1)
                                             ^
array:                                          openLinks:{"T1",pPicInPicIn}, {"T2", pSplitOut1}, {"out", pSplitOut2}


 (in) (T1) picInPic, rotate, split (T2) (out) ; (T2) vflip (T1)
                                                    ^
array: {"T2", pSplitOut1}                       openLinks:{"T1",pPicInPicIn}, {"out", pSplitOut2}


 (in) (T1) picInPic, rotate, split (T2) (out) ; (T2) vflip (T1)
                                                          ^
array: {NULL, pVFlipOut}                        openLinks:{"T1",pPicInPicIn}, {"out", pSplitOut2}


 (in) (T1) picInPic, rotate, split (T2) (out) ; (T2) vflip (T1)
                                                               ^
array:                                          openLinks: {"out", pSplitOut2}


[...]
-- 
Michael     GnuPG fingerprint: 9FF2128B147EF6730BADF133611EC787040B0FAB

I wish the Xiph folks would stop pretending they've got something they
do not.  Somehow I fear this will remain a wish. -- M?ns Rullg?rd
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 189 bytes
Desc: Digital signature
URL: <http://lists.mplayerhq.hu/pipermail/ffmpeg-devel/attachments/20080418/36995a60/attachment.pgp>



More information about the ffmpeg-devel mailing list