Browse Source

win-dshow: Use AVFrame.pts instead of AVFrame pkt_pts

AVFrame.pkt_pts was deprecated in FFmpeg commit 32c8359093d1 dated June
21, 2016 for lavc 57.24.0 (FFmpeg 3.2). AVFrame.pkt_pts was replaced by
AVFrame.pts, and it was removed in FFmpeg commit 6e30b35b85b8 [2] on
April 27, 2021. Ubuntu 18.04 has the oldest FFmpeg version we support,
FFmpeg 3.4. We should be able to safely migrate from AVFrame.pkt_pts to
AVFrame.pts.

[1]: https://github.com/FFmpeg/FFmpeg/commit/32c8359093d1ff4f45ed19518b449b3ac3769d27
[2]: https://github.com/FFmpeg/FFmpeg/commit/6e30b35b85b81c802e52a1078ec7a3097e353c6d
Ryan Foster 4 years ago
parent
commit
6d1433f228
1 changed files with 1 additions and 1 deletions
  1. 1 1
      plugins/win-dshow/ffmpeg-decode.c

+ 1 - 1
plugins/win-dshow/ffmpeg-decode.c

@@ -377,7 +377,7 @@ bool ffmpeg_decode_video(struct ffmpeg_decode *decode, uint8_t *data,
 
 	frame->range = range;
 
-	*ts = decode->frame->pkt_pts;
+	*ts = decode->frame->pts;
 
 	frame->width = decode->frame->width;
 	frame->height = decode->frame->height;