[FFmpeg-devel] Transcoding using FFmpeg

Loren Merritt lorenm
Mon Jul 2 11:38:01 CEST 2007


On Mon, 2 Jul 2007, Luca Barbato wrote:
> www.whu wrote:
>
>> 3. Transcoding in FFmpeg is performed as  decoding then encoding. The
>> computational complexity is very high compared with the partly
>> decoding then partly encoding procedure.  So do you want to add this
>> feature to FFmpeg?
>
> the idea of just adapting codec parameters w/out having a full
> decode-encode is interesting, but I think it's quite limited to alike
> codecs and could lead to really large code. If you manage to create a
> map from mpeg2 to, say mpeg4 and h264, that is less cpu intensive but
> gives comparable quality I think would be a nice addition to ffmpeg.

But it wouldn't give comparable quality. If you skip the  encoder's 
analysis phase and reuse modes and mvs from the input, then you can't 
make use of any features of the output codec that aren't in the input. 
Transcoding mpeg2 to mpeg4 like that would end up with essentially an 
mpeg2 stream except with mpeg4's entropy coder and h263 quant. 
Transcoding mpeg2 to h264 would give you cabac, but none of h264's other 
features.
This is why the only real world transcoders I've ever seen don't change 
the format, they just trancode mpeg2->mpeg2 and change the bitrate.

--Loren Merritt




More information about the ffmpeg-devel mailing list