changeset 11722:5aa83c5fb2c9 libavcodec

Cast constants to float to avoid gcc converting to and from float<->double in every operation.
author michael
date Thu, 13 May 2010 17:58:17 +0000
parents 969a7d792b79
children 87851e2b449a
files mpegaudiodec.c
diffstat 1 files changed, 2 insertions(+), 2 deletions(-) [+]
line wrap: on
line diff
--- a/mpegaudiodec.c	Thu May 13 16:32:21 2010 +0000
+++ b/mpegaudiodec.c	Thu May 13 17:58:17 2010 +0000
@@ -43,8 +43,8 @@
 #   define SHR(a,b)       ((a)*(1.0/(1<<(b))))
 #   define compute_antialias compute_antialias_float
 #   define FIXR_OLD(a)    ((int)((a) * FRAC_ONE + 0.5))
-#   define FIXR(x)        (x)
-#   define FIXHR(x)       (x)
+#   define FIXR(x)        ((float)(x))
+#   define FIXHR(x)       ((float)(x))
 #   define MULH3(x, y, s) ((s)*(y)*(x))
 #   define MULLx(x, y, s) ((y)*(x))
 #   define RENAME(a) a ## _float