Opened 5 years ago

Closed 5 years ago

Last modified 3 years ago

#8 closed defect (fixed)

Matroska muxers define unusable codec_tag properties

Reported by: EricV Owned by: michael
Priority: normal Component: avformat
Version: git-master Keywords: mkv eac3 roundup
Cc: Blocked By:
Blocking: Reproduced by developer: yes
Analyzed by developer: yes

Description

mediainfo simplified1.ts
General
ID : 1 (0x1)
Complete name : simplified1.ts
Format : MPEG-TS
File size : 120 MiB
Duration : 1mn 59s
Overall bit rate : 8 407 Kbps

Video
ID : 256 (0x100)
Menu ID : 1 (0x1)
Format : AVC
Format/Info? : Advanced Video Codec
Format profile : Main@L4.0
Format settings, CABAC : Yes
Format settings, ReFrames? : 4 frames
Format settings, GOP : M=8, N=32
Codec ID : 27
Duration : 1mn 59s
Bit rate : 7 863 Kbps
Width : 1 440 pixels
Height : 1 080 pixels
Display aspect ratio : 16:9
Frame rate : 25.000 fps
Color space : YUV
Chroma subsampling : 4:2:0
Bit depth : 8 bits
Scan type : MBAFF
Bits/(Pixel*Frame) : 0.202
Stream size : 112 MiB (93%)
Color primaries : BT.709-5, BT.1361, IEC 61966-2-4, SMPTE RP177
Transfer characteristics : BT.709-5, BT.1361
Matrix coefficients : BT.709-5, BT.1361, IEC 61966-2-4 709, SMPTE RP177

Audio
ID : 257 (0x101)
Menu ID : 1 (0x1)
Format : E-AC-3
Format/Info? : Audio Coding 3
Codec ID : 6
Duration : 2mn 0s
Bit rate mode : Constant
Bit rate : 128 Kbps
Channel(s) : 2 channels
Channel positions : Front: L R
Sampling rate : 48.0 KHz
Compression mode : Lossy
Delay relative to video : -2s 236ms
Stream size : 1.84 MiB (2%)
Language : French

Menu
ID : 4095 (0xFFF)
Menu ID : 1 (0x1)
Duration : 1mn 59s
List : 256 (0x100) (AVC) / 257 (0x101) (E-AC-3, French)
Language : / French
Service name : Service01
Service provider : FFmpeg
Service type : digital television

39 r-x-ceva6380:/network/inter-drd/Temporaires/Flux test->ffmpeg -y -i
simplified1.ts -vcodec copy -sameq -acodec copy -sameq -f matroska tf1_tnt_HD.mkv
FFmpeg version git-6a7e074, Copyright (c) 2000-2011 the FFmpeg developers

built on Mar 8 2011 10:38:12 with gcc 4.5.2
configuration: --prefix=/usr --extra-cflags='-Wall -g ' --cc='ccache cc'

--enable-shared --enable-libmp3lame --enable-gpl --enable-libvorbis
--enable-pthreads --enable-libfaac --enable-libxvid --enable-postproc
--enable-x11grab --enable-libgsm --enable-libtheora --enable-libopencore-amrnb
--enable-libopencore-amrwb --enable-libx264 --enable-libspeex --enable-nonfree
--disable-stripping --enable-avfilter --enable-libdirac
--disable-decoder=libdirac --enable-libschroedinger
--disable-encoder=libschroedinger --enable-version3 --enable-libopenjpeg
--enable-libvpx --enable-librtmp --extra-libs=-lgcrypt --disable-altivec
--disable-armv5te --disable-armv6 --disable-vis

libavutil 50. 39. 0 / 50. 39. 0
libavcodec 52.113. 2 / 52.113. 2
libavformat 52.102. 0 / 52.102. 0
libavdevice 52. 2. 3 / 52. 2. 3
libavfilter 1. 76. 0 / 1. 76. 0
libswscale 0. 12. 0 / 0. 12. 0
libpostproc 51. 2. 0 / 51. 2. 0

[h264 @ 0x8b1eca0] mmco: unref short failure
[mpegts @ 0x8b18dc0] max_analyze_duration reached

Input #0, mpegts, from 'simplified1.ts':

Duration: 00:02:01.53, start: 1.400000, bitrate: 8268 kb/s
Program 1

Metadata:

service_name : Service01
service_provider: FFmpeg

Stream #0.0[0x100]: Video: h264 (Main), yuv420p, 1440x1080 [PAR 4:3 DAR

16:9], 25 fps, 25 tbr, 90k tbn, 50 tbc

Stream #0.1[0x101](fra): Audio: eac3, 48000 Hz, stereo, s16, 128 kb/s

[matroska @ 0x8b1f450] Tag [6][0][0][0]/0x00000006 incompatible with output
codec id '86059'
Output #0, matroska, to 'tf1_tnt_HD.mkv':

Stream #0.0: Video: libx264, yuv420p, 1440x1080 [PAR 4:3 DAR 16:9], q=2-31,

90k tbn, 25 tbc

Stream #0.1(fra): Audio: [6][0][0][0] / 0x0006, 48000 Hz, stereo, 128 kb/s

Stream mapping:

Stream #0.0 -> #0.0
Stream #0.1 -> #0.1

Could not write header for output file #0 (incorrect codec parameters ?)
40 r-x-ceva6380:/network/inter-drd/Temporaires/Flux test->ffmpeg -y -i
simplified1.ts -vcodec copy -sameq -acodec eac3 -sameq -f matroska tf1_tnt_HD.mkv
FFmpeg version git-6a7e074, Copyright (c) 2000-2011 the FFmpeg developers

built on Mar 8 2011 10:38:12 with gcc 4.5.2
configuration: --prefix=/usr --extra-cflags='-Wall -g ' --cc='ccache cc'

--enable-shared --enable-libmp3lame --enable-gpl --enable-libvorbis
--enable-pthreads --enable-libfaac --enable-libxvid --enable-postproc
--enable-x11grab --enable-libgsm --enable-libtheora --enable-libopencore-amrnb
--enable-libopencore-amrwb --enable-libx264 --enable-libspeex --enable-nonfree
--disable-stripping --enable-avfilter --enable-libdirac
--disable-decoder=libdirac --enable-libschroedinger
--disable-encoder=libschroedinger --enable-version3 --enable-libopenjpeg
--enable-libvpx --enable-librtmp --extra-libs=-lgcrypt --disable-altivec
--disable-armv5te --disable-armv6 --disable-vis

libavutil 50. 39. 0 / 50. 39. 0
libavcodec 52.113. 2 / 52.113. 2
libavformat 52.102. 0 / 52.102. 0
libavdevice 52. 2. 3 / 52. 2. 3
libavfilter 1. 76. 0 / 1. 76. 0
libswscale 0. 12. 0 / 0. 12. 0
libpostproc 51. 2. 0 / 51. 2. 0

[h264 @ 0x84c9ca0] mmco: unref short failure
[mpegts @ 0x84c3dc0] max_analyze_duration reached

Input #0, mpegts, from 'simplified1.ts':

Duration: 00:02:01.53, start: 1.400000, bitrate: 8268 kb/s
Program 1

Metadata:

service_name : Service01
service_provider: FFmpeg

Stream #0.0[0x100]: Video: h264 (Main), yuv420p, 1440x1080 [PAR 4:3 DAR

16:9], 25 fps, 25 tbr, 90k tbn, 50 tbc

Stream #0.1[0x101](fra): Audio: eac3, 48000 Hz, stereo, s16, 128 kb/s

Unknown encoder 'eac3'

Change History (9)

comment:1 follow-up: Changed 5 years ago by cehoyos

  • Component changed from FFmpeg to avformat
  • Reproduced by developer set
  • Status changed from new to open
  • Summary changed from conversion of french HD tv (mpeg2ts) with eac3 audio to matroska fails to Muxing of eac3 with spectral extension into matroska is unsupported
  • Type changed from defect to enhancement

Muxing eac3 with "Spectral Extension Attenuation" into mkv is not supported, a possible sample is incoming/France2HD-EAC3-SPX.ts
(reproducible with both -map 0.1 and -map 0.2)

ffmpeg -i France2HD-EAC3-SPX.ts -map 0.2 -acodec copy -vn -sn out.mkv
FFmpeg version git-N-28415-g3efbbbb, Copyright (c) 2000-2011 the FFmpeg developers
  built on Mar 12 2011 01:38:48 with gcc 4.4.5
  configuration: --cc=/usr/local/gcc-4.4.5/bin/gcc --enable-gpl --enable-libopenjpeg
  libavutil    50. 39. 0 / 50. 39. 0
  libavcodec   52.114. 0 / 52.114. 0
  libavformat  52.103. 0 / 52.103. 0
  libavdevice  52.  3. 0 / 52.  3. 0
  libavfilter   1. 76. 0 /  1. 76. 0
  libswscale    0. 12. 0 /  0. 12. 0
[h264 @ 0x1277400] mmco: unref short failure
[mpegts @ 0x1271650] max_analyze_duration reached
Input #0, mpegts, from 'France2HD-EAC3-SPX.ts':
  Duration: 00:00:08.93, start: 11549.805367, bitrate: 6996 kb/s
  Program 1
    Stream #0.0[0xdc]: Video: h264 (Main), yuv420p, 1440x1080 [PAR 4:3 DAR 16:9], 25 fps, 25 tbr, 90k tbn, 50 tbc
    Stream #0.1[0xe7](qaa): Audio: eac3, 48000 Hz, 5.1, s16, 256 kb/s
    Stream #0.2[0xe6](fra): Audio: eac3, 48000 Hz, stereo, s16, 128 kb/s
    Stream #0.3[0xf0](fra): Subtitle: dvbsub (hearing impaired)
[matroska @ 0x1277cd0] Tag [6][0][0][0]/0x00000006 incompatible with output codec id '86059'
Output #0, matroska, to 'out.mkv':
    Stream #0.0(fra): Audio: [6][0][0][0] / 0x0006, 48000 Hz, stereo, 128 kb/s
Stream mapping:
  Stream #0.2 -> #0.0
Could not write header for output file #0 (incorrect codec parameters ?)
Last edited 5 years ago by cehoyos (previous) (diff)

comment:2 in reply to: ↑ 1 Changed 5 years ago by EricV

sorry to be picky but as eac3 is marked as supported (DE) in the codec list, why is explicitly supplying -acodec eac3 (instead of copy) failing to recognise eac3 (its related to bug vs enhancement)

Anyway thanks for verifying the problem and enhancing the description.

comment:3 Changed 5 years ago by cehoyos

If you explicitly supply -acodec eac3, ffmpeg searches for the eac3 encoder that does not exist (yet). It (correctly) outputs an error message and quits.

(Re-)Muxing eac3 in mkv is supported, but not muxing eac3 with spectral extension. One could argue that the (correct) current error message is not easily understandable, but in any case this is a feature request for muxing eac3 with spectral extension into matroska.

comment:4 Changed 5 years ago by cehoyos

And if your version of FFmpeg really outputs "E" for eac3, you have a very advanced source;-)

$ ffmpeg -codecs|grep eac3
 D A    eac3            ATSC A/52B (AC-3, E-AC-3)

comment:5 follow-up: Changed 5 years ago by cehoyos

  • Analyzed by developer set
  • Resolution set to fixed
  • Status changed from open to closed
  • Summary changed from Muxing of eac3 with spectral extension into matroska is unsupported to Matroska muxers define unusable codec_tag properties
  • Type changed from enhancement to defect
  • Version changed from git to git-master

Not really related to EAC3 (and certainly not to spectral extension).

Should be fixed in current git head.

comment:6 in reply to: ↑ 5 Changed 5 years ago by EricV

Replying to cehoyos:

Not really related to EAC3 (and certainly not to spectral extension).

Should be fixed in current git head.

The eac3 support is indeed fixed not the problem leading to "Could not write header for output file #0 (incorrect codec parameters ?)". Juts tried again with git today (N-33635-g91eb1b1)

comment:7 Changed 5 years ago by cehoyos

Please provide your command line and complete, uncut console output.

comment:8 Changed 5 years ago by EricV

See bug #537

comment:9 Changed 3 years ago by cehoyos

  • Keywords mkv eac3 roundup added
Note: See TracTickets for help on using tickets.