aboutsummaryrefslogtreecommitdiff
path: root/mesalib/src/mesa/main/macros.h
diff options
context:
space:
mode:
Diffstat (limited to 'mesalib/src/mesa/main/macros.h')
-rwxr-xr-x[-rw-r--r--]mesalib/src/mesa/main/macros.h16
1 files changed, 8 insertions, 8 deletions
diff --git a/mesalib/src/mesa/main/macros.h b/mesalib/src/mesa/main/macros.h
index e1880f59b..7a4a337d9 100644..100755
--- a/mesalib/src/mesa/main/macros.h
+++ b/mesalib/src/mesa/main/macros.h
@@ -144,10 +144,10 @@ extern GLfloat _mesa_ubyte_to_float_color_tab[256];
/* This function/macro is sensitive to precision. Test very carefully
* if you change it!
*/
-#define UNCLAMPED_FLOAT_TO_UBYTE(UB, F) \
+#define UNCLAMPED_FLOAT_TO_UBYTE(UB, FLT) \
do { \
fi_type __tmp; \
- __tmp.f = (F); \
+ __tmp.f = (FLT); \
if (__tmp.i < 0) \
UB = (GLubyte) 0; \
else if (__tmp.i >= IEEE_ONE) \
@@ -157,17 +157,17 @@ extern GLfloat _mesa_ubyte_to_float_color_tab[256];
UB = (GLubyte) __tmp.i; \
} \
} while (0)
-#define CLAMPED_FLOAT_TO_UBYTE(UB, F) \
+#define CLAMPED_FLOAT_TO_UBYTE(UB, FLT) \
do { \
fi_type __tmp; \
- __tmp.f = (F) * (255.0f/256.0f) + 32768.0f; \
+ __tmp.f = (FLT) * (255.0f/256.0f) + 32768.0f; \
UB = (GLubyte) __tmp.i; \
} while (0)
#else
-#define UNCLAMPED_FLOAT_TO_UBYTE(ub, fl) \
- ub = ((GLubyte) F_TO_I(CLAMP((fl), 0.0f, 1.0f) * 255.0f))
-#define CLAMPED_FLOAT_TO_UBYTE(ub, fl) \
- ub = ((GLubyte) F_TO_I((fl) * 255.0f))
+#define UNCLAMPED_FLOAT_TO_UBYTE(ub, FLT) \
+ ub = ((GLubyte) F_TO_I(CLAMP((FLT), 0.0f, 1.0f) * 255.0f))
+#define CLAMPED_FLOAT_TO_UBYTE(ub, FLT) \
+ ub = ((GLubyte) F_TO_I((FLT) * 255.0f))
#endif
static inline GLfloat INT_AS_FLT(GLint i)