diff mbox series

[FFmpeg-devel,5/5] lavf/mpegtsenc: enable PGS split auto bsf

Message ID 20200508141128.2684843-6-jstebbins@jetheaddev.com
State New
Headers show
Series [FFmpeg-devel,1/5] lavc/pgs_frame_merge_bsf: add bsf to merge PGS segments
Related show

Checks

Context Check Description
andriy/default pending
andriy/make success Make finished
andriy/make_fate success Make fate finished

Commit Message

John Stebbins May 8, 2020, 2:11 p.m. UTC
PGS segments must be one per packet for muxing to m2ts
---
 libavformat/mpegtsenc.c | 2 ++
 1 file changed, 2 insertions(+)
diff mbox series

Patch

diff --git a/libavformat/mpegtsenc.c b/libavformat/mpegtsenc.c
index f2be6c6632..5b86dffd0e 100644
--- a/libavformat/mpegtsenc.c
+++ b/libavformat/mpegtsenc.c
@@ -1984,6 +1984,8 @@  static int mpegts_check_bitstream(struct AVFormatContext *s, const AVPacket *pkt
                               (st->codecpar->extradata_size > 0 &&
                                st->codecpar->extradata[0] == 1)))
             ret = ff_stream_add_bitstream_filter(st, "hevc_mp4toannexb", NULL);
+    } else if (st->codecpar->codec_id == AV_CODEC_ID_HDMV_PGS_SUBTITLE) {
+        ret = ff_stream_add_bitstream_filter(st, "pgs_frame_split", NULL);
     }
 
     return ret;