summaryrefslogtreecommitdiff
path: root/src/gallium/drivers/r300/r300_state_inlines.h
diff options
context:
space:
mode:
authorCorbin Simpson <MostAwesomeDude@gmail.com>2009-02-28 11:20:26 -0800
committerCorbin Simpson <MostAwesomeDude@gmail.com>2009-02-28 11:22:40 -0800
commit2b7d39da1f5445e1b0beb3b8b1ef9004e684c600 (patch)
tree1aa01ca5bc591c5ffea72d04a9677a11c7f52e5d /src/gallium/drivers/r300/r300_state_inlines.h
parent23682dc6299ff624405eec4ea61fa504d71764c6 (diff)
r300-gallium: Move maths from r300_state to r300_state_inlines.
Diffstat (limited to 'src/gallium/drivers/r300/r300_state_inlines.h')
-rw-r--r--src/gallium/drivers/r300/r300_state_inlines.h6
1 files changed, 6 insertions, 0 deletions
diff --git a/src/gallium/drivers/r300/r300_state_inlines.h b/src/gallium/drivers/r300/r300_state_inlines.h
index 361443a692..e12540535d 100644
--- a/src/gallium/drivers/r300/r300_state_inlines.h
+++ b/src/gallium/drivers/r300/r300_state_inlines.h
@@ -28,6 +28,12 @@
#include "r300_reg.h"
+/* Some maths. These should probably find their way to u_math, if needed. */
+
+static INLINE int pack_float_16_6x(float f) {
+ return ((int)(f * 6.0) & 0xffff);
+}
+
/* Blend state. */
static INLINE uint32_t r300_translate_blend_function(int blend_func)