Opened 12 years ago

Closed 11 years ago

#531 closed defect (fixed)

failure to extract DVB-Teletext track (zero-length file)

Reported by: Brian Enigma Owned by:
Priority: normal Component: undetermined
Version: git-master Keywords: dvbsub
Cc: Blocked By:
Blocking: Reproduced by developer: yes
Analyzed by developer: no

Description

So I have two sets of transport stream files, one with a DVB-Sub subtitle track and one with a DVB-Teletext track. In both instances, there's an audio track, a video track, and a data track and ffmpeg recognizes all of them correctly. What I'd like to do is extract out just the data track (i.e. strip out the audio and video tracks) for analysis and post-processing.

In the DVB-Sub case, I can do something like this (with both ffmpeg 0.8.4 and the latest git) and everything works as expected:

ffmpeg -i file1.ts -vn -an -scodec copy -f rawvideo dvbsub.dat

When I try to do the very same thing for the DVB-Teletext track, I always end up with a zero-length file. I know there should be data in there, as I've looked at the data PID in an analyzer and can see the content of the teletext payloads. Ffmpeg sees and recognizes the stream as dvb_teletext, but it doesn't seem to want to export it. Similarly, if I attempt to extract just a program (one audio, one video, one teletext subtitle, all using the "copy" codec) from a transport stream with multiple programs, I get audio and video, but a zero-length subtitle track in the output.

Change History (9)

comment:1 by Carl Eugen Hoyos, 12 years ago

Complete, uncut output and sample missing.

comment:3 by Brian Enigma, 12 years ago

Output:

[briane@briane-linux ffmpeg-0.8.4]$ ./ffmpeg_g -i SEVEN_Digital_658M.trp -vn -an -scodec copy -f rawvideo teletext.dat
ffmpeg version 0.8.4, Copyright (c) 2000-2011 the FFmpeg developers
  built on Sep 27 2011 15:48:37 with gcc 4.1.2 20080704 (Red Hat 4.1.2-50)
  configuration: --disable-shared --enable-static
  libavutil    51.  9. 1 / 51.  9. 1
  libavcodec   53.  7. 0 / 53.  7. 0
  libavformat  53.  4. 0 / 53.  4. 0
  libavdevice  53.  1. 1 / 53.  1. 1
  libavfilter   2. 23. 0 /  2. 23. 0
  libswscale    2.  0. 0 /  2.  0. 0
[mpeg2video @ 0x1e815860] mpeg_decode_postinit() failure
    Last message repeated 2 times
[mpeg2video @ 0x1e84efc0] mpeg_decode_postinit() failure
[mp3 @ 0x1e817800] Header missing
[mpeg2video @ 0x1e848040] mpeg_decode_postinit() failure
[mpeg2video @ 0x1e84efc0] mpeg_decode_postinit() failure
[mpeg2video @ 0x1e848040] mpeg_decode_postinit() failure
[mpeg2video @ 0x1e84efc0] mpeg_decode_postinit() failure
[mpeg2video @ 0x1e815860] mpeg_decode_postinit() failure
[mpeg2video @ 0x1e848040] mpeg_decode_postinit() failure
[mpeg2video @ 0x1e84efc0] mpeg_decode_postinit() failure
    Last message repeated 4 times
[mpeg2video @ 0x1e848040] mpeg_decode_postinit() failure
[mpeg2video @ 0x1e84efc0] mpeg_decode_postinit() failure
    Last message repeated 3 times
Input #0, mpegts, from 'SEVEN_Digital_658M.trp':
  Duration: 11:08:59.23, start: 31478.449933, bitrate: 137 kb/s
  Program 1312 
    Metadata:
      service_name    : 7 Digital
      service_provider: Seven Network
    Stream #0.7[0x202]: Audio: mp2, 48000 Hz, stereo, s16, 256 kb/s
    Stream #0.0[0x204](eng): Subtitle: [6][0][0][0] / 0x0006
    Stream #0.4[0x201]: Video: mpeg2video (Main), yuv420p, 720x576 [PAR 64:45 DAR 16:9], 15000 kb/s, 25.94 fps, 25 tbr, 90k tbn, 50 tbc
  Program 1313 
    Metadata:
      service_name    : 7 Digital 1
      service_provider: Seven Network
    Stream #0.7[0x202]: Audio: mp2, 48000 Hz, stereo, s16, 256 kb/s
    Stream #0.0[0x204](eng): Subtitle: [6][0][0][0] / 0x0006
    Stream #0.4[0x201]: Video: mpeg2video (Main), yuv420p, 720x576 [PAR 64:45 DAR 16:9], 15000 kb/s, 25.94 fps, 25 tbr, 90k tbn, 50 tbc
  Program 1314 
    Metadata:
      service_name    : 7 Digital 2
      service_provider: Seven Network
    Stream #0.7[0x202]: Audio: mp2, 48000 Hz, stereo, s16, 256 kb/s
    Stream #0.0[0x204](eng): Subtitle: [6][0][0][0] / 0x0006
    Stream #0.4[0x201]: Video: mpeg2video (Main), yuv420p, 720x576 [PAR 64:45 DAR 16:9], 15000 kb/s, 25.94 fps, 25 tbr, 90k tbn, 50 tbc
  Program 1315 
    Metadata:
      service_name    : 7 Digital 3
      service_provider: Seven Network
    Stream #0.7[0x202]: Audio: mp2, 48000 Hz, stereo, s16, 256 kb/s
    Stream #0.0[0x204](eng): Subtitle: [6][0][0][0] / 0x0006
    Stream #0.4[0x201]: Video: mpeg2video (Main), yuv420p, 720x576 [PAR 64:45 DAR 16:9], 15000 kb/s, 25.94 fps, 25 tbr, 90k tbn, 50 tbc
  Program 1316 
    Metadata:
      service_name    : 7 HD Digital
      service_provider: Seven Network
    Stream #0.0[0x204](eng): Subtitle: [6][0][0][0] / 0x0006
    Stream #0.1[0x241]: Video: mpeg2video (Main), yuv420p, 720x576 [PAR 64:45 DAR 16:9], 9000 kb/s, 50.88 fps, 50 tbr, 90k tbn, 100 tbc
    Stream #0.2[0x242]: Audio: mp2, 48000 Hz, stereo, s16, 256 kb/s
    Stream #0.3[0x243]: Audio: ac3, 48000 Hz, stereo, s16, 384 kb/s
  Program 1318 
    Metadata:
      service_name    : Program Guide
      service_provider: Seven Network
    Stream #0.6[0x261]: Video: mpeg2video (Main), yuv420p, 704x576 [PAR 16:11 DAR 16:9], 1262 kb/s, 30.32 fps, 25 tbr, 90k tbn, 50 tbc
    Stream #0.5[0x262](eng): Audio: mp2, 48000 Hz, stereo, s16, 64 kb/s
Output #0, rawvideo, to 'teletext.dat':
  Metadata:
    encoder         : Lavf53.4.0
    Stream #0.0(eng): Subtitle: [6][0][0][0] / 0x0006
Stream mapping:
  Stream #0.0 -> #0.0
Press [q] to stop, [?] for help
size=       0kB time=00:00:00.00 bitrate=   0.0kbits/s    
video:0kB audio:0kB global headers:0kB muxing overhead nan%
[briane@briane-linux ffmpeg-0.8.4]$ ls -l teletext.dat 
-rw-rw-r-- 1 briane briane 0 Oct  4 09:46 teletext.dat
[briane@briane-linux ffmpeg-0.8.4]$ 
Last edited 12 years ago by Carl Eugen Hoyos (previous) (diff)

comment:4 by Carl Eugen Hoyos, 12 years ago

Reproduced by developer: set
Status: newopen
Version: gitgit-master

comment:5 by reimar, 12 years ago

Teletext packets are never marked as keyframes (no idea whether that should be considered correct or not).
You will get data if you use the -copyinkf option.

comment:6 by Carl Eugen Hoyos, 12 years ago

Keywords: dvbsub added

-copyinkf does not work anymore, afaict.

comment:7 by Carl Eugen Hoyos, 12 years ago

Possibly related to this problem, reproducible with the sample from ticket #937.
http://thread.gmane.org/gmane.comp.video.ffmpeg.user/28424/focus=35331

comment:8 by reimar, 12 years ago

Patch to fix -copyinkf sent.

comment:9 by Carl Eugen Hoyos, 11 years ago

Resolution: fixed
Status: openclosed

Fixed in FFmpeg 1.0 and current git head.

Note: See TracTickets for help on using tickets.