[FFmpeg-user] ffmpeg 608 or 708 captions

Doug Bay Doug_Bay at discovery.com
Sat Dec 8 00:12:48 CET 2012


I have XDCAM MXF with 708 and 608 captions. Here is the mediainfo output:

Format                                   : MXF
Commercial name                          : XDCAM HD422
Format profile                           : OP-1a
Format settings                          : Closed / Complete
File size                                : 18.7 GiB
Duration                                 : 44mn 25s
Overall bit rate                         : 60.1 Mbps
Encoded date                             : 2012-12-05 17:38:28.072
Writing application                      : <deleted>
Writing library                          : <deleted>

Video
ID                                       : 2
Format                                   : MPEG Video
Commercial name                          : XDCAM HD422
Format version                           : Version 2
Format profile                           : 4:2:2 at High
Format settings, BVOP                    : Yes
Format settings, Matrix                  : Default
Format settings, GOP                     : M=3, N=15
Format_Settings_Wrapping                 : Frame
Duration                                 : 44mn 25s
Bit rate                                 : 50.0 Mbps
Width                                    : 1 920 pixels
Height                                   : 1 080 pixels
Display aspect ratio                     : 16:9
Frame rate                               : 29.970 fps
Color space                              : YUV
Chroma subsampling                       : 4:2:2
Bit depth                                : 8 bits
Scan type                                : Interlaced
Scan order                               : Top Field First
Compression mode                         : Lossy
Bits/(Pixel*Frame)                       : 0.805
Stream size                              : 15.5 GiB (83%)
Delay_SDTI                               : 3520000

Text #1
ID                                       : 11-CC1
Format                                   : EIA-608
Muxing mode                              : Ancillary data / CDP
Bit rate mode                            : Constant
Stream size                              : 0.00 Byte (0%)
Delay_SDTI                               : 3520000
Text #2
ID                                       : 11-1
Format                                   : EIA-708
Muxing mode                              : Ancillary data / CDP
Duration                                 : 44mn 25s
Bit rate mode                            : Constant
Stream size                              : 0.00 Byte (0%)

But I dont think ffmpeg is sing Text 1 and Text 2. Here is the ffprob output:



 Metadata:
    timecode        : 00:58:40;00
  Duration: 00:44:25.06, start: 0.000000, bitrate: 60139 kb/s
    Stream #0:0: Video: mpeg2video (4:2:2), yuv422p, 1920x1080 [SAR 1:1 DAR 16:9], 29.97 fps, 29.97 tbr, 29.97 tbn, 59.94 tbc
    Stream #0:1: Audio: pcm_s24le, 48000 Hz, 1 channels, s32, 1152 kb/s
    Stream #0:2: Audio: pcm_s24le, 48000 Hz, 1 channels, s32, 1152 kb/s
    Stream #0:3: Audio: pcm_s24le, 48000 Hz, 1 channels, s32, 1152 kb/s
    Stream #0:4: Audio: pcm_s24le, 48000 Hz, 1 channels, s32, 1152 kb/s
    Stream #0:5: Audio: pcm_s24le, 48000 Hz, 1 channels, s32, 1152 kb/s
    Stream #0:6: Audio: pcm_s24le, 48000 Hz, 1 channels, s32, 1152 kb/s
    Stream #0:7: Audio: pcm_s24le, 48000 Hz, 1 channels, s32, 1152 kb/s
    Stream #0:8: Audio: pcm_s24le, 48000 Hz, 1 channels, s32, 1152 kb/s
    Stream #0:9: Data: none

I am guessing Stream 0:9 Data should be captions, or atlease captions should show up as a stream.

 In anycase when I run FFMPEG to extract captions to text file, nothing gets extracted. Here is the output:



ffmpeg -i video.mxf  -an -vn -bsf:s mov2textsub -scodec copy -f rawvideo captions.txt
ffmpeg version git-2012-11-28-f7eb50f Copyright (c) 2000-2012 the FFmpeg developers
  built on Dec  7 2012 14:11:42 with gcc 4.4.5 (Debian 4.4.5-8)
  configuration:
  libavutil      52.  9.102 / 52.  9.102
  libavcodec     54. 77.100 / 54. 77.100
  libavformat    54. 39.100 / 54. 39.100
  libavdevice    54.  3.100 / 54.  3.100
  libavfilter     3. 23.104 /  3. 23.104
  libswscale      2.  1.102 /  2.  1.102
  libswresample   0. 17.101 /  0. 17.101
[mxf @ 0x9506500] could not resolve sub descriptor strong ref
[mxf @ 0x9506500] source track 11: stream 9, no descriptor found
[mxf @ 0x9506500] Stream #9: not enough frames to estimate rate; consider increasing probesize
Guessed Channel Layout for  Input Stream #0.1 : mono
Guessed Channel Layout for  Input Stream #0.2 : mono
Guessed Channel Layout for  Input Stream #0.3 : mono
Guessed Channel Layout for  Input Stream #0.4 : mono
Guessed Channel Layout for  Input Stream #0.5 : mono
Guessed Channel Layout for  Input Stream #0.6 : mono
Guessed Channel Layout for  Input Stream #0.7 : mono
Guessed Channel Layout for  Input Stream #0.8 : mono
Input #0, mxf, from '/mnt/pathfinder_xcode_output/Agility/mxf/DSC_026103_151_05_001_16x9 1080i 50Mb 422 XDCAM HD_1.mxf':
  Metadata:
    timecode        : 00:58:40;00
  Duration: 00:44:25.06, start: 0.000000, bitrate: 60139 kb/s
    Stream #0:0: Video: mpeg2video (4:2:2), yuv422p, 1920x1080 [SAR 1:1 DAR 16:9], 29.97 fps, 29.97 tbr, 29.97 tbn, 59.94 tbc
    Stream #0:1: Audio: pcm_s24le, 48000 Hz, mono, s32, 1152 kb/s
    Stream #0:2: Audio: pcm_s24le, 48000 Hz, mono, s32, 1152 kb/s
    Stream #0:3: Audio: pcm_s24le, 48000 Hz, mono, s32, 1152 kb/s
    Stream #0:4: Audio: pcm_s24le, 48000 Hz, mono, s32, 1152 kb/s
    Stream #0:5: Audio: pcm_s24le, 48000 Hz, mono, s32, 1152 kb/s
    Stream #0:6: Audio: pcm_s24le, 48000 Hz, mono, s32, 1152 kb/s
    Stream #0:7: Audio: pcm_s24le, 48000 Hz, mono, s32, 1152 kb/s
    Stream #0:8: Audio: pcm_s24le, 48000 Hz, mono, s32, 1152 kb/s
    Stream #0:9: Data: none
Output #0, rawvideo, to '/workspace/captiontest/MXF.txt':
  Metadata:
    timecode        : 00:58:40;00
Output file #0 does not contain any stream

The captions.txt file has nothing written to it. It seems to me that its not seeing the 708 and 608 track of captions that I know are there from seeing it and analyzing it with mediafinfo. Has anyone had success in extracting 708 or 608 captions and can tell me what I'm doing wrong?




________________________________________
From: ffmpeg-user-bounces at ffmpeg.org [ffmpeg-user-bounces at ffmpeg.org] on behalf of Carl Eugen Hoyos [cehoyos at ag.or.at]
Sent: Friday, December 07, 2012 5:51 PM
To: ffmpeg-user at ffmpeg.org
Subject: Re: [FFmpeg-user] ffmpeg 608 or 708 captions

Doug Bay <Doug_Bay <at> discovery.com> writes:

> Can ffmpeg decode 608 or 708 captions and save them to a text file?

Please test, if it does not work, provide samples.

Carl Eugen

_______________________________________________
ffmpeg-user mailing list
ffmpeg-user at ffmpeg.org
http://ffmpeg.org/mailman/listinfo/ffmpeg-user

This e-mail, and any attachment, is intended only for the person or entity to which it is addressed and may contain confidential and/or privileged material. Any review, re-transmission, copying, dissemination or other use of this information by persons or entities other than the intended recipient is prohibited. If you received this in error, please contact the sender and delete the material from any computer. The contents of this message may contain personal views which are not the views of Discovery Communications, Inc.


More information about the ffmpeg-user mailing list