On 10/13/2012 03:45 PM, Christian Schmidt wrote:
> ---
>  libavcodec/pcm-mpeg.c | 4 ++--
>  1 file changed, 2 insertions(+), 2 deletions(-)
> 
> diff --git a/libavcodec/pcm-mpeg.c b/libavcodec/pcm-mpeg.c
> index 4a38648..602abab 100644
> --- a/libavcodec/pcm-mpeg.c
> +++ b/libavcodec/pcm-mpeg.c
> @@ -109,12 +109,12 @@ static int pcm_bluray_parse_header(AVCodecContext 
> *avctx,
>          return -1;
>      }
>  
> -    avctx->bit_rate = avctx->channels * avctx->sample_rate *
> +    avctx->bit_rate = FFALIGN(avctx->channels,2) * avctx->sample_rate *
>                        avctx->bits_per_coded_sample;

Why channels must be a multiple of 2? Would be nice mentioning it in the
commit message.

>      if (avctx->debug & FF_DEBUG_PICT_INFO)
>          av_dlog(avctx,
> -                "pcm_bluray_parse_header: %d channels, %d bits per sample, 
> %d kHz, %d kbit\n",
> +                "pcm_bluray_parse_header: %d channels, %d bits per sample, 
> %d Hz, %d bit/s\n",
>                  avctx->channels, avctx->bits_per_coded_sample,
>                  avctx->sample_rate, avctx->bit_rate);
>      return 0;

This is obviously correct.

_______________________________________________
libav-devel mailing list
libav-devel@libav.org
https://lists.libav.org/mailman/listinfo/libav-devel

Reply via email to