[FFmpeg-devel] [PATCH 1/2] lavfi/af_anequalizer: replace pow(10, x) by ff_exp10(x)

Ganesh Ajjanagadde gajjanagadde at gmail.com
Mon Dec 28 01:51:21 CET 2015


Signed-off-by: Ganesh Ajjanagadde <gajjanagadde at gmail.com>
---
 libavfilter/af_anequalizer.c | 18 +++++++++---------
 1 file changed, 9 insertions(+), 9 deletions(-)

diff --git a/libavfilter/af_anequalizer.c b/libavfilter/af_anequalizer.c
index e45c108..d7b5b6c 100644
--- a/libavfilter/af_anequalizer.c
+++ b/libavfilter/af_anequalizer.c
@@ -316,9 +316,9 @@ static void butterworth_bp_filter(EqualizatorFilter *f,
         return;
     }
 
-    G  = pow(10, G/20);
-    Gb = pow(10, Gb/20);
-    G0 = pow(10, G0/20);
+    G  = ff_exp10(G/20);
+    Gb = ff_exp10(Gb/20);
+    G0 = ff_exp10(G0/20);
 
     epsilon = sqrt((G * G - Gb * Gb) / (Gb * Gb - G0 * G0));
     g  = pow(G,  1.0 / N);
@@ -385,9 +385,9 @@ static void chebyshev1_bp_filter(EqualizatorFilter *f,
         return;
     }
 
-    G  = pow(10, G/20);
-    Gb = pow(10, Gb/20);
-    G0 = pow(10, G0/20);
+    G  = ff_exp10(G/20);
+    Gb = ff_exp10(Gb/20);
+    G0 = ff_exp10(G0/20);
 
     epsilon = sqrt((G*G - Gb*Gb) / (Gb*Gb - G0*G0));
     g0 = pow(G0,1.0/N);
@@ -458,9 +458,9 @@ static void chebyshev2_bp_filter(EqualizatorFilter *f,
         return;
     }
 
-    G  = pow(10, G/20);
-    Gb = pow(10, Gb/20);
-    G0 = pow(10, G0/20);
+    G  = ff_exp10(G/20);
+    Gb = ff_exp10(Gb/20);
+    G0 = ff_exp10(G0/20);
 
     epsilon = sqrt((G*G - Gb*Gb) / (Gb*Gb - G0*G0));
     g  = pow(G, 1.0 / N);
-- 
2.6.4



More information about the ffmpeg-devel mailing list