Opened 10 years ago

Closed 10 years ago

Last modified 10 years ago

#3351 closed defect (fixed)

IMX D10 File Encoding Fails to Produce Valid IMX File

Reported by: Steve Owned by:
Priority: important Component: avformat
Version: git-master Keywords: imx mov regression
Cc: Blocked By:
Blocking: Reproduced by developer: yes
Analyzed by developer: no

Description

After moving from v1.0.8 to v2.1.1, encoding a file to Quicktime IMX format no longer works.

Produces an output file that plays but the VBI area is visible and it is not recognised as an IMX file. Just a quicktime file with mpeg2video as the video codec.

/usr/local/bin/ffmpeg -i "Input_2.mov" -map 0:v -map 0:a -vf "scale=720:576:1,pad=720:608:0:32:black" -c:v mpeg2video -r 25 -pix_fmt yuv422p -minrate 50000k -maxrate 50000k -b:v 50000k -intra -flags +ildct+ilme+low_delay -intra_vlc 1 -non_linear_quant 1 -ps 1 -qmin 1 -qmax 3 -top 1 -dc 10 -bufsize 2000000 -rc_init_occupancy 2000000 -rc_buf_aggressivity 0.25 -bsf:v imxdump -tag:v? mx5p -c:a pcm_s16le -ar 48000 -y "Output_IMX_4.mov"
ffmpeg version 2.1 Copyright (c) 2000-2013 the FFmpeg developers

built on Nov 20 2013 18:32:36 with gcc 4.2.1 (GCC) 20070831 patched [FeeBSD]
configuration: --enable-libaacplus --disable-indev=alsa --disable-outdev=alsa --disable-libopencore-amrnb --disable-libopencore-amrwb --disable-libass --disable-libcdio --disable-libcelt --disable-libfaac --disable-libfdk-aac --enable-ffserver --enable-fontconfig --enable-libfreetype --enable-frei0r --enable-gnutls --disable-libgsm --enable-iconv --disable-indev=jack --enable-libmp3lame --disable-libbluray --enable-libv4l2 --disable-libmodplug --disable-openal --disable-indev=openal --enable-libopencv --enable-libopenjpeg --disable-libopus --disable-libpulse --disable-indev=pulse --disable-outdev=pulse --disable-librtmp --enable-libschroedinger --disable-libspeex --enable-libtheora --disable-vaapi --disable-vdpau --enable-libvorbis --disable-libvo-aacenc --disable-libvo-amrwbenc --enable-libvpx --enable-libx264 --enable-libxvid --prefix=/usr/local --mandir=/usr/local/man --datadir=/usr/local/share/ffmpeg --enable-shared --enable-gpl --enable-postproc --enable-avfilter --enable-avresample --enable-pthreads --enable-memalign-hack --disable-libstagefright-h264 --disable-libutvideo --disable-libsoxr --cc=cc --extra-cflags='-msse -I/usr/local/include/vorbis -I/usr/local/include' --extra-ldflags='-L/usr/local/lib ' --extra-libs=-pthread --disable-debug --disable-ffplay --disable-outdev=sdl --enable-nonfree
libavutil 52. 48.100 / 52. 48.100
libavcodec 55. 39.100 / 55. 39.100
libavformat 55. 19.104 / 55. 19.104
libavdevice 55. 5.100 / 55. 5.100
libavfilter 3. 90.100 / 3. 90.100
libavresample 1. 1. 0 / 1. 1. 0
libswscale 2. 5.101 / 2. 5.101
libswresample 0. 17.104 / 0. 17.104
libpostproc 52. 3.100 / 52. 3.100

[mov,mp4,m4a,3gp,3g2,mj2 @ 0x8088db420] sample aspect ratio already set to 118:81, ignoring 'pasp' atom (64:45)
Guessed Channel Layout for Input Stream #0.1 : stereo
Input #0, mov,mp4,m4a,3gp,3g2,mj2, from 'Input_2.mov':

Metadata:

major_brand : qt
minor_version : 537199360
compatible_brands: qt
creation_time : 2013-12-06 14:58:35

Duration: 00:00:10.00, start: 0.000000, bitrate: 30339 kb/s

Stream #0:0(eng): Video: dvvideo (dvcp / 0x70637664), yuv420p, 720x576 [SAR 64:45 DAR 16:9], 28800 kb/s, SAR 118:81 DAR 295:162, 25 fps, 25 tbr, 25 tbn, 25 tbc (default)
Metadata:

creation_time : 2013-12-06 14:58:35
handler_name : Apple Alias Data Handler

Stream #0:1(eng): Audio: pcm_s16le (sowt / 0x74776F73), 48000 Hz, stereo, s16, 1536 kb/s (default)
Metadata:

creation_time : 2013-12-06 14:58:35
handler_name : Apple Alias Data Handler

Output #0, mov, to 'Output_IMX_4.mov':

Metadata:

major_brand : qt
minor_version : 537199360
compatible_brands: qt
encoder : Lavf55.19.104
Stream #0:0(eng): Video: mpeg2video (mx5p / 0x7035786D), yuv422p, 720x608 [SAR 118:81 DAR 295:171], q=1-3, 50000 kb/s, 12800 tbn, 25 tbc (default)
Metadata:

creation_time : 2013-12-06 14:58:35
handler_name : Apple Alias Data Handler

Stream #0:1(eng): Audio: pcm_s16le (sowt / 0x74776F73), 48000 Hz, stereo, s16, 1536 kb/s (default)
Metadata:

creation_time : 2013-12-06 14:58:35
handler_name : Apple Alias Data Handler

Stream mapping:

Stream #0:0 -> #0:0 (dvvideo -> mpeg2video)
Stream #0:1 -> #0:1 (pcm_s16le -> pcm_s16le)

Press [q] to stop, ? for help
frame= 250 fps= 89 q=1.6 Lsize= 62919kB time=00:00:10.00 bitrate=51543.4kbits/s
video:61035kB audio:1875kB subtitle:0 global headers:0kB muxing overhead 0.014360%

ffprobe of output file

ffprobe Output_IMX_4.mov
ffprobe version 2.1.1 Copyright (c) 2007-2013 the FFmpeg developers

built on Jan 12 2014 03:43:26 with gcc 4.2.1 (GCC) 20070831 patched [FeeBSD]
configuration: --enable-libaacplus --disable-indev=alsa --disable-outdev=alsa --disable-libopencore-amrnb --disable-libopencore-amrwb --disable-libass --disable-libcdio --disable-libcelt --enable-libfaac --disable-libfdk-aac --enable-ffserver --enable-fontconfig --disable-libfreetype --enable-frei0r --enable-gnutls --disable-libgsm --enable-iconv --disable-indev=jack --enable-libmp3lame --disable-libbluray --enable-libv4l2 --disable-libmodplug --disable-openal --disable-indev=openal --enable-libopencv --enable-libopenjpeg --disable-libopus --disable-libpulse --disable-indev=pulse --disable-outdev=pulse --disable-librtmp --enable-libschroedinger --disable-libspeex --enable-libtheora --disable-vaapi --disable-vdpau --enable-libvorbis --disable-libvo-aacenc --disable-libvo-amrwbenc --enable-libvpx --enable-libx264 --enable-libxvid --prefix=/usr/local --mandir=/usr/local/man --datadir=/usr/local/share/ffmpeg --enable-shared --enable-gpl --enable-postproc --enable-avfilter --enable-avresample --enable-pthreads --enable-memalign-hack --disable-libstagefright-h264 --disable-libutvideo --disable-libsoxr --cc=cc --extra-cflags='-msse -I/usr/local/include/vorbis -I/usr/local/include' --extra-ldflags='-L/usr/local/lib ' --extra-libs=-pthread --disable-debug --disable-ffplay --disable-outdev=sdl --enable-nonfree
libavutil 52. 48.101 / 52. 48.101
libavcodec 55. 39.101 / 55. 39.101
libavformat 55. 19.104 / 55. 19.104
libavdevice 55. 5.100 / 55. 5.100
libavfilter 3. 90.100 / 3. 90.100
libavresample 1. 1. 0 / 1. 1. 0
libswscale 2. 5.101 / 2. 5.101
libswresample 0. 17.104 / 0. 17.104
libpostproc 52. 3.100 / 52. 3.100

Input #0, mov,mp4,m4a,3gp,3g2,mj2, from 'Output_IMX_4.mov':

Metadata:

major_brand : qt
minor_version : 512
compatible_brands: qt
encoder : Lavf55.19.104

Duration: 00:00:10.00, start: 0.000000, bitrate: 51543 kb/s

Stream #0:0(eng): Video: mpeg2video (4:2:2) (m2v1 / 0x3176326D), yuv422p(tv), 720x608 [SAR 608:405 DAR 16:9], 50004 kb/s, SAR 118:81 DAR 295:171, 25 fps, 25 tbr, 12800 tbn, 50 tbc (default)
Metadata:

handler_name : DataHandler

Stream #0:1(eng): Audio: pcm_s16le (sowt / 0x74776F73), 48000 Hz, stereo, s16, 1536 kb/s (default)
Metadata:

handler_name : DataHandler

Encoded attempted with ffmpeg 2.1.1 from FreeBSD ports

Attachments (1)

patchimx.diff (777 bytes ) - added by Carl Eugen Hoyos 10 years ago.

Download all attachments as: .zip

Change History (10)

in reply to:  description comment:1 by Carl Eugen Hoyos, 10 years ago

Keywords: imxdump mx5p removed

Replying to steven:

Encoded attempted with ffmpeg 2.1.1 from FreeBSD ports

Is the problem also reproducible with current FFmpeg git head?

How can I reproduce that the encoded file is bad?

comment:2 by Carl Eugen Hoyos, 10 years ago

Keywords: regression added
Priority: normalimportant
Version: unspecified

Please test these two versions (I suspect I have found the offending commit, but I don't know how to test):
e4d45673 and 713dcdbf

by Carl Eugen Hoyos, 10 years ago

Attachment: patchimx.diff added

comment:3 by Carl Eugen Hoyos, 10 years ago

Please test if attached patch from Michael fixes the issue for you.

comment:4 by Steve, 10 years ago

Forgive my ignorance but do you know if the current githead + patch will compile without modification on FreeBSD? If not what is the best linux distro to use? I'll spin up a VM with it and test on there.

Thanks

in reply to:  4 comment:5 by Carl Eugen Hoyos, 10 years ago

Replying to steven:

Forgive my ignorance but do you know if the current githead + patch will compile without modification on FreeBSD?

If not that would be an important bug that we would (very much!) like to know about.

Just in case you don't know: The preferred way of compilation is $ ./configure && make ffmpeg, you don't have to install to test (I absolutely never install) and you should really install yasm 1.2, it is a standalone binary. (You of course need a working C compiler and GNU make.)

comment:6 by Carl Eugen Hoyos, 10 years ago

Any news on this?
I don't know how to test this issue (can I test it easily?), so if you want this fixed, please test the suggested versions (to confirm the issue) and the attached patch.

comment:7 by Carl Eugen Hoyos, 10 years ago

Component: undeterminedavformat
Keywords: mov added; imx removed
Reproduced by developer: set
Status: newopen
Version: unspecifiedgit-master

I can confirm that this is a regression since e4d45673 and that attached patch by Michael fixes the issue.

comment:8 by Carl Eugen Hoyos, 10 years ago

Resolution: fixed
Status: openclosed

Fixed by Michael in 72d44f15

comment:9 by Carl Eugen Hoyos, 10 years ago

Keywords: imx added
Note: See TracTickets for help on using tickets.