[xiph-commits] r14186 - trunk/speex/libspeex
jm at svn.xiph.org
jm at svn.xiph.org
Mon Nov 19 05:16:03 PST 2007
Author: jm
Date: 2007-11-19 05:16:03 -0800 (Mon, 19 Nov 2007)
New Revision: 14186
Modified:
trunk/speex/libspeex/preprocess.c
Log:
Reverted API change on the AGC because it would bite too many
people.
Modified: trunk/speex/libspeex/preprocess.c
===================================================================
--- trunk/speex/libspeex/preprocess.c 2007-11-19 12:54:38 UTC (rev 14185)
+++ trunk/speex/libspeex/preprocess.c 2007-11-19 13:16:03 UTC (rev 14186)
@@ -1065,17 +1065,18 @@
case SPEEX_PREPROCESS_GET_AGC:
(*(spx_int32_t*)ptr) = st->agc_enabled;
break;
-
+#ifndef DISABLE_FLOAT_API
case SPEEX_PREPROCESS_SET_AGC_LEVEL:
- st->agc_level = (*(spx_int32_t*)ptr);
+ st->agc_level = (*(float*)ptr);
if (st->agc_level<1)
st->agc_level=1;
if (st->agc_level>32768)
st->agc_level=32768;
break;
case SPEEX_PREPROCESS_GET_AGC_LEVEL:
- (*(spx_int32_t*)ptr) = st->agc_level;
+ (*(float*)ptr) = st->agc_level;
break;
+#endif /* #ifndef DISABLE_FLOAT_API */
case SPEEX_PREPROCESS_SET_AGC_INCREMENT:
st->max_increase_step = exp(0.11513f * (*(spx_int32_t*)ptr)*st->frame_size / st->sampling_rate);
break;
More information about the commits
mailing list