Fix missing subtitles embedded in files decoded by FFmpeg (#2060).
authorCarl Hetherington <cth@carlh.net>
Sun, 12 Sep 2021 20:43:52 +0000 (22:43 +0200)
committerCarl Hetherington <cth@carlh.net>
Sun, 12 Sep 2021 23:22:00 +0000 (01:22 +0200)
commit60450bd93af0b331d7b98c88aa199366305f0721
tree23451d313c8e83f74fb2be6d99656cbf98cb21d9
parentdf811a0dd2772417496991b72fde0ef3304241d9
Fix missing subtitles embedded in files decoded by FFmpeg (#2060).

Since the FFmpeg 4.4 update it seems that AVSubtitle::pts is no longer
set (it's AV_NOPTS_VALUE, i think).

Instead we apparently need to get the PTS from the packet, which in
turn requires the stream's timebase.
src/lib/ffmpeg.cc
src/lib/ffmpeg.h
src/lib/ffmpeg_decoder.cc