[vlc-devel] [PATCH 2/2] codec: avcodec: use filtered/best effort pts
Steve Lhomme
robux4 at ycbcr.xyz
Fri Feb 5 14:55:23 UTC 2021
LGTM if it's on all supported versions of ffmpeg.
On 2021-02-05 15:33, Francois Cartegnie wrote:
> fixes playback/stuttering with wrong mux/monotonically
> increasing pts on frames that must be reordered.
>
> no change for regular pts.
> ---
> modules/codec/avcodec/video.c | 4 ++++
> 1 file changed, 4 insertions(+)
>
> diff --git a/modules/codec/avcodec/video.c b/modules/codec/avcodec/video.c
> index baff3e46214..8872fba0a03 100644
> --- a/modules/codec/avcodec/video.c
> +++ b/modules/codec/avcodec/video.c
> @@ -1079,7 +1079,11 @@ static int DecodeBlock( decoder_t *p_dec, block_t **pp_block )
>
> /* Compute the PTS */
> #if LIBAVCODEC_VERSION_CHECK( 57, 24, 0, 61, 100 )
> +# if LIBAVCODEC_VERSION_MICRO >= 100
> + int64_t av_pts = frame->best_effort_timestamp;
> +# else
> int64_t av_pts = frame->pts;
> +# endif
> #else
> int64_t av_pts = frame->pkt_pts;
> #endif
> --
> 2.26.2
>
> _______________________________________________
> vlc-devel mailing list
> To unsubscribe or modify your subscription options:
> https://mailman.videolan.org/listinfo/vlc-devel
>
More information about the vlc-devel
mailing list