You've already forked FFmpeg
mirror of
https://github.com/FFmpeg/FFmpeg.git
synced 2025-07-11 14:30:22 +02:00
mpegtsenc: Write subtitle extradata if set
Originally committed as revision 25221 to svn://svn.ffmpeg.org/ffmpeg/trunk
This commit is contained in:
@ -276,8 +276,13 @@ static void mpegts_write_pmt(AVFormatContext *s, MpegTSService *service)
|
|||||||
*q++ = language[1];
|
*q++ = language[1];
|
||||||
*q++ = language[2];
|
*q++ = language[2];
|
||||||
*q++ = 0x10; /* normal subtitles (0x20 = if hearing pb) */
|
*q++ = 0x10; /* normal subtitles (0x20 = if hearing pb) */
|
||||||
|
if(st->codec->extradata_size == 4) {
|
||||||
|
memcpy(q, st->codec->extradata, 4);
|
||||||
|
q += 4;
|
||||||
|
} else {
|
||||||
put16(&q, 1); /* page id */
|
put16(&q, 1); /* page id */
|
||||||
put16(&q, 1); /* ancillary page id */
|
put16(&q, 1); /* ancillary page id */
|
||||||
|
}
|
||||||
}
|
}
|
||||||
break;
|
break;
|
||||||
case AVMEDIA_TYPE_VIDEO:
|
case AVMEDIA_TYPE_VIDEO:
|
||||||
|
Reference in New Issue
Block a user