]> git.sesse.net Git - ffmpeg/blobdiff - libavcodec/acelp_vectors.c
avcodec: Drop long-deprecated imgconvert.h header
[ffmpeg] / libavcodec / acelp_vectors.c
index 25a6ff27df09b416fcb86b43de464713d1a49a12..b50c5f3ffe25db5945068d04151124800f53d336 100644 (file)
  */
 
 #include <inttypes.h>
+
+#include "libavutil/common.h"
 #include "avcodec.h"
+#include "dsputil.h"
 #include "acelp_vectors.h"
-#include "celp_math.h"
 
 const uint8_t ff_fc_2pulses_9bits_track1[16] =
 {
@@ -48,26 +50,6 @@ const uint8_t ff_fc_2pulses_9bits_track1_gray[16] =
   28, 26,
 };
 
-const uint8_t ff_fc_2pulses_9bits_track2_gray[32] =
-{
-  0,  2,
-  5,  4,
-  12, 10,
-  7,  9,
-  25, 24,
-  20, 22,
-  14, 15,
-  19, 17,
-  36, 31,
-  21, 26,
-  1,  6,
-  16, 11,
-  27, 29,
-  32, 30,
-  39, 37,
-  34, 35,
-};
-
 const uint8_t ff_fc_4pulses_8bits_tracks_13[16] =
 {
   0, 5, 10, 15, 20, 25, 30, 35, 40, 45, 50, 55, 60, 65, 70, 75,
@@ -201,7 +183,7 @@ void ff_adaptive_gain_control(float *out, const float *in, float speech_energ,
                               int size, float alpha, float *gain_mem)
 {
     int i;
-    float postfilter_energ = ff_dot_productf(in, in, size);
+    float postfilter_energ = ff_scalarproduct_float_c(in, in, size);
     float gain_scale_factor = 1.0;
     float mem = *gain_mem;
 
@@ -222,7 +204,7 @@ void ff_scale_vector_to_given_sum_of_squares(float *out, const float *in,
                                              float sum_of_squares, const int n)
 {
     int i;
-    float scalefactor = ff_dot_productf(in, in, n);
+    float scalefactor = ff_scalarproduct_float_c(in, in, n);
     if (scalefactor)
         scalefactor = sqrt(sum_of_squares / scalefactor);
     for (i = 0; i < n; i++)