summaryrefslogtreecommitdiff
path: root/src/mesa/main/compiler.h
diff options
context:
space:
mode:
authorIan Romanick <ian.d.romanick@intel.com>2010-11-24 14:03:57 -0800
committerIan Romanick <ian.d.romanick@intel.com>2010-12-01 12:01:12 -0800
commitda61afa7388f1ce50ef612b89aba2302a052a3bb (patch)
treeb27ec804556251c48095098e0c911674615d43ac /src/mesa/main/compiler.h
parentd2d7a273c51127677d394d1bb9484a2d85c5dcd2 (diff)
glsl: Use M_LOG2E constant instead of calling log2
Diffstat (limited to 'src/mesa/main/compiler.h')
-rw-r--r--src/mesa/main/compiler.h4
1 files changed, 4 insertions, 0 deletions
diff --git a/src/mesa/main/compiler.h b/src/mesa/main/compiler.h
index 800eb83900..5557a3b5cb 100644
--- a/src/mesa/main/compiler.h
+++ b/src/mesa/main/compiler.h
@@ -358,6 +358,10 @@ static INLINE GLuint CPU_TO_LE32(GLuint x)
#define M_E (2.7182818284590452354)
#endif
+#ifndef M_LOG2E
+#define M_LOG2E (1.4426950408889634074)
+#endif
+
#ifndef ONE_DIV_LN2
#define ONE_DIV_LN2 (1.442695040888963456)
#endif