Commit 0b1e94c5 authored by Michael Niedermayer's avatar Michael Niedermayer

Revert "Merge commit '9f1eccb9'"

This unbreaks muxing-encoding
Example:
ffmpeg -i matrixbench_mpeg2.mpg new.avi

-rw-r----- 1 michael michael 226035354 Jan  1 16:27 new.avi
-rw-r----- 1 michael michael  10016802 Jan  1 16:28 ref.avi

Also av_get_audio_frame_duration() itself uses frame_size

This reverts commit 29e6606e, reversing
changes made to 53448461.
parent 92fe2adc
......@@ -242,7 +242,12 @@ void ff_parse_specific_params(AVStream *st, int *au_rate,
int gcd;
int audio_frame_size;
/* We use the known constant frame size for the codec if known, otherwise
* fall back on using AVCodecContext.frame_size, which is not as reliable
* for indicating packet duration. */
audio_frame_size = av_get_audio_frame_duration(codec, 0);
if (!audio_frame_size)
audio_frame_size = codec->frame_size;
*au_ssize = codec->block_align;
if (audio_frame_size && codec->sample_rate) {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment