2012/1/26 Maksym Veremeyenko <ve...@m1stereo.tv>: > 25.01.12 19:55, Dan Dennedy написав(ла): > >> On Wed, Jan 25, 2012 at 9:43 AM, Dan Dennedy<d...@dennedy.org> wrote: >>> >>> 2012/1/25 Maksym Veremeyenko<ve...@m1stereo.tv>: >>>> >>>> 25.01.12 19:24, Dan Dennedy написав(ла): >>>> >>>>> On Wed, Jan 25, 2012 at 8:16 AM, Maksym Veremeyenko<ve...@m1stereo.tv> >>>>> wrote: >>>>>> >>>>>> >>>>>> Hi, >>>>>> >>>>>> are there any way to set (or use) *loop* or *eof* properties for >>>>>> *avformat* producer? >>>>> >>>>> >>>>> >>>>> Yes, I think it should, but it depends on your context (object model) >>>>> and application to enable the proper behavior. IOW, the playlist or >>>>> multitrack length might be limiting the duration. Also, it appears >>>>> that the playlist sets eof=pause when you add the producer to a >>>>> playlist. So, eof needs to be set after the playlist operation. Also, >>>>> the playlist producer supports an eof property itself that can be a >>>>> factor. >>>>> >>>> >>>> it seems i have to use playlist for playing loop... >>>> >>>> command >>>> >>>> melt test.dv eof=loop >>>> >>>> do not work properly for me, is it correct? >>> >>> >>> Correct, that is what I implied by "context." melt does is not >>> concerned to easily support this use case (but there might be a tricky >>> way to do it). Melt always creates a multitrack with a playlist for a >>> track. The most obvious way to simulate a loop with melt is to use >>> -repeat with a large value. You will need to dig a little if you need >>> a real loop by using a mlt xml file or by tricking the command line >>> options. >> >> >> I had a vague recollection that I had figured out a command line >> trick. So, I searched my e-mail and found it: >> >> melt eof=loop test.dv >> >> In the options processor, initially the current properties object is >> the tractor, which is a producer that understands eof property >> semantics. So, here we set a property on the tractor producer before >> creating a new producer, which changes the current properties object. >> > > i had a success with C code to provide a loop throw a mlt_playlist, but for > xml i can't provide this. i did a simple demo with background video and some > small animation on it: > > <?xml version="1.0" ?> > <mlt> > <!-- clip --> > <producer id="clip"> > <property name="resource">I0009618_test.avi</property> > </producer> > <!-- cg --> > <producer id="cg"> > <property name="resource">globe_SD.avi</property> > </producer> > <!-- cg loop --> > <playlist id="cg_loop" eof="loop"> > <entry producer="cg"/> > </playlist> > <tractor> > <multitrack> > <track producer="cg_loop"/> > <track producer="clip"/> > </multitrack> > <!-- clip and cg blending --> > <transition in="0.0" out="1499.0"> > <property name="mlt_service">composite</property> > <property name="a_track">1</property> > <property name="b_track">0</property> > <property name="progressive">1</property> > <property name="start">0/0:100%x100%:100</property> > <property name="end">0/0:100%x100%:100</property> > <property name="halign">left</property> > <property name="valign">top</property> > <property name="distort">0</property> > </transition> > </tractor> > </mlt> >
It depends on the app that is consumer the xml. If it is melt, then the xml is loaded as a virtual clip within a multitrack/tractor created by producer_melt, and you still need to set eof=loop on the tractor . A producer cannot be forever. At the most, it is INT_MAX frames long. Then, you need to make sure the "outermost" producer has some looping as you did with a playlist in code. -- +-DRD-+ ------------------------------------------------------------------------------ Keep Your Developer Skills Current with LearnDevNow! The most comprehensive online learning library for Microsoft developers is just $99.99! Visual Studio, SharePoint, SQL - plus HTML5, CSS3, MVC3, Metro Style Apps, more. Free future releases when you subscribe now! http://p.sf.net/sfu/learndevnow-d2d _______________________________________________ Mlt-devel mailing list Mlt-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/mlt-devel