avvidenc: Set the DTS to 0 if it is negative, not the PTS

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/6505>
This commit is contained in:
Sebastian Dröge 2024-05-01 16:39:00 +03:00 committed by GStreamer Marge Bot
parent ee518b9c7e
commit dc0aebbea0

View file

@ -735,7 +735,7 @@ gst_ffmpegvidenc_receive_packet (GstFFMpegVidEnc * ffmpegenc,
ffmpegenc->context->time_base);
if (gst_pts_dts_diff > frame->pts)
frame->pts = 0;
frame->dts = 0;
else
frame->dts = frame->pts - gst_pts_dts_diff;
} else {