[FFmpeg-devel] [PATCH] fftools/ffmpeg_opt: Add -toeof option to stop writing relative to EOF

Gyan Doshi gyandoshi at gmail.com
Sun Jun 10 21:26:30 EEST 2018



On 10-06-2018 10:01 PM, morten.with at gmail.com wrote:



> +    if (o->stop_time_eof != AV_NOPTS_VALUE) {
> +        if (ic->duration>0) {
> +            o->recording_time = ic->duration + o->stop_time_eof;
> +        } else
> +            av_log(NULL, AV_LOG_WARNING, "Cannot use -toeof, duration of %s not known\n", filename);


You need to make sure input -t and -to are both not set. You need to 
check that sseof if set isn't greater than toeof. And ss if set isn't 
beyond toeof either.

Your recording time has to account for a input start from the middle of 
the file.

Regards,
Gyan


More information about the ffmpeg-devel mailing list