]> granicus.if.org Git - handbrake/commitdiff
stream: add support for eia 608 subtitle tracks
authorJohn Stebbins <jstebbins.hb@gmail.com>
Wed, 17 Jul 2019 17:13:20 +0000 (10:13 -0700)
committerJohn Stebbins <jstebbins.hb@gmail.com>
Wed, 17 Jul 2019 17:15:52 +0000 (10:15 -0700)
eia 608 embedded in video was supported (i.e. ffmpeg frame side
data AV_FRAME_DATA_A53_CC), but not as it's own track.

Fixes https://github.com/HandBrake/HandBrake/issues/1300

libhb/stream.c

index 1fa7018270961f74a24a0abe17c0115080fda264..d95ef8ad36b186fbd68c1e98bb78c06b8d3301fa 100644 (file)
@@ -5455,6 +5455,13 @@ static void add_ffmpeg_subtitle( hb_title_t *title, hb_stream_t *stream, int id
             subtitle->config.dest = RENDERSUB;
             subtitle->codec = WORK_DECPGSSUB;
             break;
+        case AV_CODEC_ID_EIA_608:
+            subtitle->format = TEXTSUB;
+            subtitle->source = CC608SUB;
+            subtitle->config.dest = PASSTHRUSUB;
+            subtitle->codec = WORK_DECCC608;
+            subtitle->attributes  = HB_SUBTITLE_ATTR_CC;
+            break;
         default:
             hb_log( "add_ffmpeg_subtitle: unknown subtitle stream type: 0x%x",
                     (int) codecpar->codec_id );