Opened 14 months ago

Closed 13 days ago

#6783 closed enhancement (fixed)

Remuxing pcm_dvd does not work

Reported by: cehoyos Owned by:
Priority: wish Component: avformat
Version: git-master Keywords: mpegps pcm_dvd
Cc: Blocked By:
Blocking: Reproduced by developer: no
Analyzed by developer: no

Description

$ ffmpeg -i fate-suite/pcm-dvd/coolitnow-partial.vob -vcodec copy -acodec copy out.vob
ffmpeg version N-88204-g7f9de7b Copyright (c) 2000-2017 the FFmpeg developers
  built with gcc 6.3.0 (GCC)
  configuration: --enable-gpl
  libavutil      56.  0.100 / 56.  0.100
  libavcodec     58.  0.101 / 58.  0.101
  libavformat    58.  0.101 / 58.  0.101
  libavdevice    58.  0.100 / 58.  0.100
  libavfilter     7.  0.100 /  7.  0.100
  libswscale      5.  0.100 /  5.  0.100
  libswresample   3.  0.100 /  3.  0.100
  libpostproc    55.  0.100 / 55.  0.100
[mpeg2video @ 0x3240c80] Invalid frame dimensions 0x0.
    Last message repeated 8 times
Guessed Channel Layout for Input Stream #0.1 : stereo
Input #0, mpeg, from 'fate-suite/pcm-dvd/coolitnow-partial.vob':
  Duration: 00:00:00.94, start: 138.868633, bitrate: 8945 kb/s
    Stream #0:0[0x1e0]: Video: mpeg2video (Main), yuv420p(tv, smpte170m, top first), 720x480 [SAR 8:9 DAR 4:3], 29.97 fps, 29.97 tbr, 90k tbn, 59.94 tbc
    Stream #0:1[0xa0]: Audio: pcm_dvd, 48000 Hz, stereo, s32 (24 bit), 2304 kb/s
    Stream #0:2[0x1bf]: Data: dvd_nav_packet
[svcd @ 0x32afa60] VBV buffer size not set, using default size of 130KB
If you want the mpeg file to be compliant to some specification
Like DVD, VCD or others, make sure you set the correct buffer size
Output #0, svcd, to 'out.vob':
  Metadata:
    encoder         : Lavf58.0.101
    Stream #0:0: Video: mpeg2video (Main), yuv420p(tv, smpte170m, top first), 720x480 [SAR 8:9 DAR 4:3], q=2-31, 29.97 fps, 29.97 tbr, 90k tbn, 29.97 tbc
    Stream #0:1: Audio: pcm_dvd, 48000 Hz, stereo, s32 (24 bit), 2304 kb/s
Stream mapping:
  Stream #0:0 -> #0:0 (copy)
  Stream #0:1 -> #0:1 (copy)
Press [q] to stop, [?] for help
[svcd @ 0x32afa60] Timestamps are unset in a packet for stream 0. This is deprecated and will stop working in the future. Fix your code to set the timestamps properly
frame=   17 fps=0.0 q=-1.0 Lsize=     766kB time=00:00:01.07 bitrate=5858.1kbits/s speed= 361x
video:511kB audio:241kB subtitle:0kB other streams:0kB global headers:0kB muxing overhead: 1.905638%
$ ffmpeg -i out.vob
ffmpeg version N-88204-g7f9de7b Copyright (c) 2000-2017 the FFmpeg developers
  built with gcc 6.3.0 (GCC)
  configuration: --enable-gpl
  libavutil      56.  0.100 / 56.  0.100
  libavcodec     58.  0.101 / 58.  0.101
  libavformat    58.  0.101 / 58.  0.101
  libavdevice    58.  0.100 / 58.  0.100
  libavfilter     7.  0.100 /  7.  0.100
  libswscale      5.  0.100 /  5.  0.100
  libswresample   3.  0.100 /  3.  0.100
  libpostproc    55.  0.100 / 55.  0.100
[mp2 @ 0x22f5aa0] Header missing
    Last message repeated 142 times
[mpeg @ 0x22f4240] decoding for stream 0 failed
[mpeg @ 0x22f4240] Could not find codec parameters for stream 0 (Audio: mp2, 0 channels, s16p): unspecified frame size
Consider increasing the value for the 'analyzeduration' and 'probesize' options
Input #0, mpeg, from 'out.vob':
  Duration: 00:00:01.10, start: 0.500000, bitrate: 5681 kb/s
    Stream #0:0[0x1c0]: Audio: mp2, 0 channels, s16p
    Stream #0:1[0x1e0]: Video: mpeg2video (Main), yuv420p(tv, smpte170m, top first), 720x480 [SAR 8:9 DAR 4:3], 29.97 fps, 29.97 tbr, 90k tbn, 59.94 tbc
At least one output file must be specified

Change History (10)

comment:1 Changed 5 months ago by mjbrown

Just to be clear, is this a problem which only happens when the input video has an invalid frame size?

Doubtful that anyone will be taking a look at it without a sample file attached.

comment:2 Changed 5 months ago by Gyan

For 16-bit streams, this was fixed in f0809bc0fa634afe8b7c3f2682b8e51e87d0861e

For higher bit-depths, the packet header routine in the muxer needs to be changed (right now, hardcoded for 16-bit) as well as the data layout of the stream for which a new bitstream filter will be needed. See the pcm dvd decoder for details about both the header and the layout.

Last edited 5 months ago by Gyan (previous) (diff)

comment:3 Changed 3 weeks ago by Sami32

In case it could help, here is a VOB sample containing a 24-bit PCM stream:
https://samples.libav.org/MPEG-VOB/LPCM/lpcm.vob

comment:4 Changed 3 weeks ago by cehoyos

Is anything wrong with our sample?
https://samples.ffmpeg.org/MPEG-VOB/LPCM/lpcm.vob

comment:5 Changed 3 weeks ago by cehoyos

Or with the sample from my original report?

comment:6 Changed 3 weeks ago by Sami32

And for completness, here one with 20-bit LPCM: (see the file named VTS_08_1.VOB)
http://download.videohelp.com/jsoto/AudioTests/VTS_05_10.rar

Note:
Some more 20 and 24-bit little samples can be found into these archives:
http://download.videohelp.com/jsoto/AudioTests/VTS_11_15.rar
http://download.videohelp.com/jsoto/AudioTests/VTS_16_18.rar
https://wiki.multimedia.cx/index.php/PCM

Last edited 3 weeks ago by Sami32 (previous) (diff)

comment:7 Changed 3 weeks ago by cehoyos

http://samples.ffmpeg.org/ffmpeg-bugs/trac/ticket3122/

We usually mention it if we are missing samples...

comment:8 Changed 3 weeks ago by Sami32

@Carl

mjbrown

"Just to be clear, is this a problem which only happens when the input video has an invalid frame size?

Doubtful that anyone will be taking a look at it without a sample file attached."

Like him i could not see any sample attached to this issue, so i just did to avoid other people than FFmpeg developpers to contribute without having to guess and decrypt if and where are possible samples...

Last edited 3 weeks ago by Sami32 (previous) (diff)

comment:9 Changed 3 weeks ago by cehoyos

The location of the original sample is very carefully hidden in the given command line, as you found out, we have several other samples (that are less likely to be already on a developer's system).

comment:10 Changed 13 days ago by cehoyos

  • Resolution set to fixed
  • Status changed from new to closed
Note: See TracTickets for help on using tickets.