[FFmpeg-devel] [PATCH] ffmpeg: count finished streams for last stats line.

Michael Niedermayer michaelni at gmx.at
Tue Aug 28 23:54:46 CEST 2012


On Tue, Aug 28, 2012 at 11:39:30PM +0200, Nicolas George wrote:
> Otherwise, all streams are finished and the time is nonsensical.
> 
> Signed-off-by: Nicolas George <nicolas.george at normalesup.org>
> ---
>  ffmpeg.c |    2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/ffmpeg.c b/ffmpeg.c
> index 58308c9..a980303 100644
> --- a/ffmpeg.c
> +++ b/ffmpeg.c
> @@ -1154,7 +1154,7 @@ static void print_report(int is_last_report, int64_t timer_start, int64_t cur_ti
>              vid = 1;
>          }
>          /* compute min output value */
> -        if (!ost->finished && ost->st->pts.val != AV_NOPTS_VALUE)
> +        if ((is_last_report || !ost->finished) && ost->st->pts.val != AV_NOPTS_VALUE)
>              pts = FFMAX(pts, av_rescale_q(ost->st->pts.val,
>                                            ost->st->time_base, AV_TIME_BASE_Q));
>      }

LGTM

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

I know you won't believe me, but the highest form of Human Excellence is
to question oneself and others. -- Socrates
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 198 bytes
Desc: Digital signature
URL: <http://ffmpeg.org/pipermail/ffmpeg-devel/attachments/20120828/8f29ee61/attachment.asc>


More information about the ffmpeg-devel mailing list