[FFmpeg-devel] [PATCH] lavc/libopusenc: report an error if global_quality is set.

Nicolas George nicolas.george at normalesup.org
Sun Feb 24 12:16:39 CET 2013


Le quintidi 25 pluviôse, an CCXXI, Nicolas George a écrit :
> 
> Signed-off-by: Nicolas George <nicolas.george at normalesup.org>
> ---
>  libavcodec/libopusenc.c |    7 +++++++
>  1 file changed, 7 insertions(+)
> 
> diff --git a/libavcodec/libopusenc.c b/libavcodec/libopusenc.c
> index d198798..a4aa37c 100644
> --- a/libavcodec/libopusenc.c
> +++ b/libavcodec/libopusenc.c
> @@ -107,6 +107,13 @@ static int libopus_configure_encoder(AVCodecContext *avctx, OpusMSEncoder *enc,
>  {
>      int ret;
>  
> +    if (avctx->global_quality) {
> +        av_log(avctx, AV_LOG_ERROR,
> +               "Quality-based encoding not supported, "
> +               "please specify a bitrate and VBR setting.\n");
> +        return AVERROR(EINVAL);
> +    }
> +
>      ret = opus_multistream_encoder_ctl(enc, OPUS_SET_BITRATE(avctx->bit_rate));
>      if (ret != OPUS_OK) {
>          av_log(avctx, AV_LOG_ERROR,

Ping? I will push soon if nobody objects.

Regards,

-- 
  Nicolas George
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 198 bytes
Desc: Digital signature
URL: <http://ffmpeg.org/pipermail/ffmpeg-devel/attachments/20130224/50750031/attachment.asc>


More information about the ffmpeg-devel mailing list