Commit 8d38e5e5 authored by Oded Shimon's avatar Oded Shimon

Original Commit: r97 | ods15 | 2006-09-30 23:32:19 +0300 (Sat, 30 Sep 2006) | 2 lines

don't assert fail for channels != 2, exit cleanly instead...

Originally committed as revision 6501 to svn://svn.ffmpeg.org/ffmpeg/trunk
parent 7a82a10a
...@@ -1057,6 +1057,8 @@ static int vorbis_encode_init(AVCodecContext * avccontext) ...@@ -1057,6 +1057,8 @@ static int vorbis_encode_init(AVCodecContext * avccontext)
{ {
venc_context_t * venc = avccontext->priv_data; venc_context_t * venc = avccontext->priv_data;
if (avccontext->channels != 2) return -1;
create_vorbis_context(venc, avccontext); create_vorbis_context(venc, avccontext);
if (avccontext->flags & CODEC_FLAG_QSCALE) venc->quality = avccontext->global_quality / (float)FF_QP2LAMBDA / 100.; if (avccontext->flags & CODEC_FLAG_QSCALE) venc->quality = avccontext->global_quality / (float)FF_QP2LAMBDA / 100.;
......
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