[FFmpeg-devel] [PATCH] Make ffmpeg -t X with X<=0 transcode nothing

Stefano Sabatini stefano.sabatini-lala
Sat Jul 19 00:25:25 CEST 2008


On date Friday 2008-07-18 01:58:27 +0200, Michael Niedermayer encoded:
>  On Fri, Jul 18, 2008 at 12:27:33AM +0200, Stefano Sabatini wrote:
> > On date Thursday 2008-07-17 22:18:08 +0200, Michael Niedermayer encoded:
> > > On Thu, Jul 17, 2008 at 08:57:09PM +0200, Stefano Sabatini wrote:
> > [...]
> > > > But if we can avoid *at all* to transcode then I'm fine, ideally a:
> > > > ffmpeg -t 0 -i test.avi -sdp -f rtp -an rtp://test.mpeg > test.sdp
> > > > 
> > > > should be fine, if *no* transcoding is performed then the return code
> > > > tells if we wrote that SDP or not, which isn't guaranteed if we have
> > > > to set t > 0.
> > > 
> > > > So can anyone explain why it is necessary to set t > 0?, attached patch
> > > > is a first naive attempt to fix the t>0 issue.
> > > 
> > > what is t by default? what will you patch do in that case? ...
> > 
> > Yes, anyway if the user writes:
> > ffmpeg -t 0 -i test.avi -y test.mpeg
> > 
> > then I think he expects to transcode *nothing* rather than the whole
> > file, this also according to the docs:
> > 
> > @item -t @var{duration}
> > Restrict the transcoded/captured video sequence
> > to the duration specified in seconds.
> > @code{hh:mm:ss[.xxx]} syntax is also supported.
> > 
> > New patch attached, this also doesn't break the default behaviour when
> > -t isn't specified.
> 
> ok

Committed.
-- 
FFmpeg = Fast and Fiendish Mega Problematic Elitarian Game




More information about the ffmpeg-devel mailing list