diff acelp_vectors.h @ 10463:9f35b262d3f0 libavcodec

Commit some functions that are used by both SIPR and AMR. Based on AMR SoC code by Robert Swain and Colin McQuillan.
author vitor
date Tue, 27 Oct 2009 23:53:18 +0000
parents 139d30c8c274
children 5f2ced30548b
line wrap: on
line diff
--- a/acelp_vectors.h	Tue Oct 27 20:56:56 2009 +0000
+++ b/acelp_vectors.h	Tue Oct 27 23:53:18 2009 +0000
@@ -164,4 +164,16 @@
 void ff_weighted_vector_sumf(float *out, const float *in_a, const float *in_b,
                              float weight_coeff_a, float weight_coeff_b, int length);
 
+/**
+ * Adaptative gain control (as used in AMR postfiltering)
+ *
+ * @param buf_out the input speech buffer
+ * @param speech_energ input energy
+ * @param size the input buffer size
+ * @param alpha exponential filter factor
+ * @param gain_mem a pointer to the filter memory (single float of size)
+ */
+void ff_adaptative_gain_control(float *buf_out, float speech_energ,
+                                int size, float alpha, float *gain_mem);
+
 #endif /* AVCODEC_ACELP_VECTORS_H */