Jump to content

EIA-608 closed captions in MP4 files aren't displayed


Recommended Posts

Today I found that video files containing embedded closed captions, such as DVB recordings or iTunes downloads, will show that subtitles are present but none of my clients are able to display them and the server is not able to transcode them to a usable format. This example is from the iTunes Store.




In the local and remote webapps some corrupted text is shown:




The Android client behaves like the webapps. The Kodi plugin and Samsung Orsay client both display nothing at all but detect the correct language.


The Emby's log shows ffmpeg bombing out:


Stream #0:0(eng): Subtitle: subrip (srt), 1280x720 (default)
creation_time : 2016-12-07T11:23:24.000000Z
encoder : Lavc57.64.100 srt
Stream mapping:
Stream #0:2 -> #0:0 (eia_608 (cc_dec) -> subrip (srt))
Press [q] to stop, [?] for help
[Closed caption Decoder @ 0xa9ca000] Data Ignored since exceeding screen width
Last message repeated 2029 times
size= 1kB time=00:19:50.89 bitrate= 0.0kbits/s speed=1.52e+04x
video:0kB audio:0kB subtitle:1kB other streams:0kB global headers:0kB muxing overhead: 52.568306%


The root cause is a known deficiency in ffmpeg which can identify the caption stream correctly but cannot extract it, refer to https://trac.ffmpeg.org/ticket/4616 which also has a sample video attached. I would be curious to know if iOS devices are able to DirectPlay this type of content with working captions.




To extract usable subtitles from a video simply run the file through CCExtractor (http://ccextractor.sourceforge.net), generally you will not need to specify any special options as the defaults will produce an external SubRip (.srt) file as output. To get rid of the unusable caption stream (or replace it with the SubRip subtitles) simply remux the file to Matroska using mkvtoolnix or avimux.

Edited by OddbOd
Link to comment
Share on other sites

  • 4 years later...



I can send you a UK DVB stream with CC's if that's of any use Luke ?

edit - Actually DVBSUB are already picked up and usable as Subtitles - so I think you have those covered already.. ?

Edited by rbjtech
Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

  • Create New...