[libav-bugs] [Bug 440] New: avconv does not copy all audiostreams and subtitles using -c: copy
bugzilla-daemon at aruru.libav.org
bugzilla-daemon at aruru.libav.org
Sat Feb 2 13:02:25 CET 2013
https://bugzilla.libav.org/show_bug.cgi?id=440
Summary: avconv does not copy all audiostreams and subtitles
using -c: copy
Product: Libav
Version: 0.8
Platform: All
OS/Version: Linux
Status: NEW
Severity: normal
Priority: Normal
Component: general
AssignedTo: bugzilla at libav.org
ReportedBy: ramon at kukla.info
Hello,
I have a couple of mkv-files create by makemkv(.com) always including all
english and german audiostreams/subtitles. Since these file are uncompressed I
would like to compress the videostream and just copy the rest (audio and sub).
In my opinion avconv should be the tool because the man-page says "An empty
stream specifier matches all streams, for example "-codec copy" or "-codec:
copy" would copy all the streams without reencoding."
Here is an example file.
avconv version 0.8.5-4:0.8.5-0ubuntu0.12.04.1, Copyright (c) 2000-2012 the
Libav developers
built on Jan 24 2013 18:01:36 with gcc 4.6.3
[matroska,webm @ 0x1f117a0] max_analyze_duration reached
[matroska,webm @ 0x1f117a0] Estimating duration from bitrate, this may be
inaccurate
Input #0, matroska,webm, from 'input.mkv':
Duration: 00:40:58.44, start: 0.000000, bitrate: 7884 kb/s
Chapter #0.0: start 0.000000, end 535.400000
Metadata:
title : Chapter 01
Chapter #0.1: start 535.400000, end 921.120000
Metadata:
title : Chapter 02
Chapter #0.2: start 921.120000, end 1386.560000
Metadata:
title : Chapter 03
Chapter #0.3: start 1386.560000, end 1787.280000
Metadata:
title : Chapter 04
Chapter #0.4: start 1787.280000, end 2420.800000
Metadata:
title : Chapter 05
Chapter #0.5: start 2420.800000, end 2458.440000
Metadata:
title : Chapter 06
Stream #0.0(eng): Video: mpeg2video (Main), yuv420p, 720x576 [PAR 64:45 DAR
16:9], 7500 kb/s, 25 fps, 25 tbr, 1k tbn, 50 tbc
Stream #0.1(ger): Audio: ac3, 48000 Hz, stereo, s16, 192 kb/s (default)
Metadata:
title : 2/0
Stream #0.2(eng): Audio: ac3, 48000 Hz, stereo, s16, 192 kb/s
Metadata:
title : 2/0
Stream #0.3(ger): Subtitle: dvdsub (default)
Stream #0.4(ger): Subtitle: dvdsub
Stream #0.5(eng): Subtitle: dvdsub
At least one output file must be specified
Now I try to compress/encode the videostream while keeping my audio and
subtitles:
avconv -i input.mkv -c:v mpeg2video -acodec copy -scodec copy -b:v 5000k
-maxrate:v 6000k -bufsize 1835k output.mkv
This is the (first part) of the output generated by avconv:
avconv version 0.8.5-4:0.8.5-0ubuntu0.12.04.1, Copyright (c) 2000-2012 the
Libav developers
built on Jan 24 2013 18:01:36 with gcc 4.6.3
[matroska,webm @ 0x24097a0] max_analyze_duration reached
[matroska,webm @ 0x24097a0] Estimating duration from bitrate, this may be
inaccurate
Input #0, matroska,webm, from 'input.mkv':
Duration: 00:40:58.44, start: 0.000000, bitrate: 7884 kb/s
Chapter #0.0: start 0.000000, end 535.400000
Metadata:
title : Chapter 01
Chapter #0.1: start 535.400000, end 921.120000
Metadata:
title : Chapter 02
Chapter #0.2: start 921.120000, end 1386.560000
Metadata:
title : Chapter 03
Chapter #0.3: start 1386.560000, end 1787.280000
Metadata:
title : Chapter 04
Chapter #0.4: start 1787.280000, end 2420.800000
Metadata:
title : Chapter 05
Chapter #0.5: start 2420.800000, end 2458.440000
Metadata:
title : Chapter 06
Stream #0.0(eng): Video: mpeg2video (Main), yuv420p, 720x576 [PAR 64:45 DAR
16:9], 7500 kb/s, 25 fps, 25 tbr, 1k tbn, 50 tbc
Stream #0.1(ger): Audio: ac3, 48000 Hz, stereo, s16, 192 kb/s (default)
Metadata:
title : 2/0
Stream #0.2(eng): Audio: ac3, 48000 Hz, stereo, s16, 192 kb/s
Metadata:
title : 2/0
Stream #0.3(ger): Subtitle: dvdsub (default)
Stream #0.4(ger): Subtitle: dvdsub
Stream #0.5(eng): Subtitle: dvdsub
File 'output.mkv' already exists. Overwrite ? [y/N] y
[buffer @ 0x2554b00] w:720 h:576 pixfmt:yuv420p
Output #0, matroska, to 'output.mkv':
Metadata:
encoder : Lavf53.21.1
Chapter #0.0: start 0.000000, end 535.400000
Metadata:
title : Chapter 01
Chapter #0.1: start 535.400000, end 921.120000
Metadata:
title : Chapter 02
Chapter #0.2: start 921.120000, end 1386.560000
Metadata:
title : Chapter 03
Chapter #0.3: start 1386.560000, end 1787.280000
Metadata:
title : Chapter 04
Chapter #0.4: start 1787.280000, end 2420.800000
Metadata:
title : Chapter 05
Chapter #0.5: start 2420.800000, end 2458.440000
Metadata:
title : Chapter 06
Stream #0.0(eng): Video: mpeg2video, yuv420p, 720x576 [PAR 64:45 DAR 16:9],
q=2-31, 5000 kb/s, 1k tbn, 25 tbc
Stream #0.1(ger): Audio: ac3, 48000 Hz, stereo, 192 kb/s (default)
Metadata:
title : 2/0
Stream #0.2(ger): Subtitle: dvdsub (default)
Stream mapping:
Stream #0:0 -> #0:0 (mpeg2video -> mpeg2video)
Stream #0:1 -> #0:1 (copy)
Stream #0:3 -> #0:2 (copy)
Press ctrl-c to stop encoding
[mpeg2video @ 0x240d140] warning: first frame is no keyframe
[mpeg2video @ 0x246e680] rc buffer underflow
[mpeg2video @ 0x240d140] warning: first frame is no keyframe
frame= 431 fps= 94 q=2.0 size= 3788kB time=16.64 bitrate=1864.7kbits/s
dup=0 drop=1
As you can see avconv just copy the first audiostream and subtitle. I also
tried "-c:a copy" instead of "-acodec copy" with the same result. I am running
avconv version 0.8.5-4:0.8.5-0ubuntu0.12.04.1 on Ubuntu 12.04.1 LTS. Here is
the output from "avconv -v 9 -loglevel 99 -i input.mkv":
avconv version 0.8.5-4:0.8.5-0ubuntu0.12.04.1, Copyright (c) 2000-2012 the
Libav developers
built on Jan 24 2013 18:01:36 with gcc 4.6.3
configuration: --extra-version='4:0.8.5-0ubuntu0.12.04.1' --arch=amd64
--prefix=/usr --libdir=/usr/lib/x86_64-linux-gnu --enable-vdpau --enable-bzlib
--enable-libgsm --enable-libschroedinger --enable-libspeex --enable-libtheora
--enable-libvorbis --enable-pthreads --enable-zlib --enable-libvpx
--enable-runtime-cpudetect --enable-libfreetype --enable-vaapi --enable-gpl
--enable-postproc --enable-swscale --enable-x11grab --enable-libdc1394
--shlibdir=/usr/lib/x86_64-linux-gnu --enable-shared --disable-static
libavutil 51. 22. 1 / 51. 22. 1
libavcodec 53. 35. 0 / 53. 35. 0
libavformat 53. 21. 1 / 53. 21. 1
libavdevice 53. 2. 0 / 53. 2. 0
libavfilter 2. 15. 0 / 2. 15. 0
libswscale 2. 1. 0 / 2. 1. 0
libpostproc 52. 0. 0 / 52. 0. 0
[matroska,webm @ 0x15c57a0] Probed with size=2048 and score=100
st:0 removing common factor 1000000 from timebase
st:1 removing common factor 1000000 from timebase
st:2 removing common factor 1000000 from timebase
st:3 removing common factor 1000000 from timebase
st:4 removing common factor 1000000 from timebase
st:5 removing common factor 1000000 from timebase
[mpeg2video @ 0x15c9140] err{or,}_recognition separate: 1; 1
[mpeg2video @ 0x15c9140] err{or,}_recognition combined: 1; 1
[ac3 @ 0x15cb060] err{or,}_recognition separate: 1; 1
[ac3 @ 0x15cb060] err{or,}_recognition combined: 1; 1
[ac3 @ 0x15cb060] Unsupported bit depth: 0
[ac3 @ 0x15ccea0] err{or,}_recognition separate: 1; 1
[ac3 @ 0x15ccea0] err{or,}_recognition combined: 1; 1
[ac3 @ 0x15ccea0] Unsupported bit depth: 0
[dvdsub @ 0x15cd6c0] err{or,}_recognition separate: 1; 1
[dvdsub @ 0x15cd6c0] err{or,}_recognition combined: 1; 1
[dvdsub @ 0x15d8f00] err{or,}_recognition separate: 1; 1
[dvdsub @ 0x15d8f00] err{or,}_recognition combined: 1; 1
[dvdsub @ 0x15dafa0] err{or,}_recognition separate: 1; 1
[dvdsub @ 0x15dafa0] err{or,}_recognition combined: 1; 1
[mpeg2video @ 0x15c9140] Unsupported bit depth: 0
[matroska,webm @ 0x15c57a0] max_analyze_duration reached
[matroska,webm @ 0x15c57a0] Estimating duration from bitrate, this may be
inaccurate
Input #0, matroska,webm, from 'input.mkv':
Duration: 00:40:58.44, start: 0.000000, bitrate: 7884 kb/s
Chapter #0.0: start 0.000000, end 535.400000
Metadata:
title : Chapter 01
Chapter #0.1: start 535.400000, end 921.120000
Metadata:
title : Chapter 02
Chapter #0.2: start 921.120000, end 1386.560000
Metadata:
title : Chapter 03
Chapter #0.3: start 1386.560000, end 1787.280000
Metadata:
title : Chapter 04
Chapter #0.4: start 1787.280000, end 2420.800000
Metadata:
title : Chapter 05
Chapter #0.5: start 2420.800000, end 2458.440000
Metadata:
title : Chapter 06
Stream #0.0(eng), 127, 1/1000: Video: mpeg2video (Main), yuv420p, 720x576
[PAR 64:45 DAR 16:9], 1/50, 7500 kb/s, 25 fps, 25 tbr, 1k tbn, 50 tbc
Stream #0.1(ger), 159, 1/1000: Audio: ac3, 48000 Hz, stereo, s16, 192 kb/s
(default)
Metadata:
title : 2/0
Stream #0.2(eng), 159, 1/1000: Audio: ac3, 48000 Hz, stereo, s16, 192 kb/s
Metadata:
title : 2/0
Stream #0.3(ger), 0, 1/1000: Subtitle: dvdsub (default)
Stream #0.4(ger), 0, 1/1000: Subtitle: dvdsub
Stream #0.5(eng), 0, 1/1000: Subtitle: dvdsub
At least one output file must be specified
regards!
--
Configure bugmail: https://bugzilla.libav.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are watching all bug changes.
More information about the libav-bugs
mailing list