Ticket #477 (closed defect: needs_more_info)
Unnecessary h264 -> libx264 conversion when using copy video codec
| Reported by: | redirect77 | Owned by: | michael |
|---|---|---|---|
| Priority: | minor | Component: | FFmpeg |
| Version: | git-master | Keywords: | |
| Cc: | Blocked By: | ||
| Blocking: | Reproduced by developer: | no | |
| Analyzed by developer: | no |
Description
I'm trying to multiplex video and audio stream into a single file, by using the "copy" codec for both video and audio.
The video stream is a H.264 encoded, stored in MKV file format.
The audio stream is an AAC encoded, stored in MKV file format.
The command line I'm using is:
ffmpeg.exe -y -i video.mkv -vcodec copy -i audio.mkv -acodec copy -f matroska clip.mkv
, which, according to documentation should multiplex video and audio stream into a single MKV file without re-conversion. This is indeed the case for the audio stream, however for the video stream it performs completely unnecessary h264 -> libx264 conversion.
The ffmpeg executable in question is statically built with MinGW build environment to include libx264, using the Git repository source code, downloaded on 16.09.2011.
It should be also noted, that such problem doesn't occur, when the executable is build from the 0.8.3 release source code.
Change History
comment:1 Changed 20 months ago by cehoyos
- Status changed from new to closed
- Resolution set to invalid
comment:2 Changed 20 months ago by redirect77
- Status changed from closed to reopened
- Resolution invalid deleted
Modification of the command line to:
ffmpeg.exe -y -i video.mkv -i audio.mkv -vcodec copy -acodec copy clip.mkv
doesn't remedy the problem with binaries, compiled from Git repository source code.
Also, in 0.8.3 release code, the problem doesn't occur no matter of the sequence of the parameters - both command lines perform a multiplex without recoding as expected.



(complete, uncut output missing.)
To affect the output file (clip.mkv), -vcodec copy has to be put in front of it (like -acodec copy).
The way you use it, -vcodec copy affects the input file audio.mkv (where it has no effect):