<div dir="ltr">THANK YOU!!!!! I've been wanting to see this happen for a long time.<br></div><div class="gmail_extra"><br><div class="gmail_quote">On Sun, Oct 16, 2016 at 7:07 PM, Dave Airlie <span dir="ltr"><<a href="mailto:airlied@gmail.com" target="_blank">airlied@gmail.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">From: Dave Airlie <<a href="mailto:airlied@redhat.com">airlied@redhat.com</a>><br>
<br>
Although the vulkan drivers include mesa macros.h, for<br>
radv I'd like to move away from that.<br>
<br>
Signed-off-by: Dave Airlie <<a href="mailto:airlied@redhat.com">airlied@redhat.com</a>><br>
---<br>
src/mesa/main/macros.h | 13 -------------<br>
src/util/macros.h | 13 +++++++++++++<br>
2 files changed, 13 insertions(+), 13 deletions(-)<br>
<br>
diff --git a/src/mesa/main/macros.h b/src/mesa/main/macros.h<br>
index ed207d4..03a228b 100644<br>
--- a/src/mesa/main/macros.h<br>
+++ b/src/mesa/main/macros.h<br>
@@ -660,19 +660,6 @@ INTERP_4F(GLfloat t, GLfloat dst[4], const GLfloat out[4], const GLfloat in[4])<br>
<br>
<br>
<br>
-/** Clamp X to [MIN,MAX] */<br>
-#define CLAMP( X, MIN, MAX ) ( (X)<(MIN) ? (MIN) : ((X)>(MAX) ? (MAX) : (X)) )<br>
-<br>
-/** Minimum of two values: */<br>
-#define MIN2( A, B ) ( (A)<(B) ? (A) : (B) )<br>
-<br>
-/** Maximum of two values: */<br>
-#define MAX2( A, B ) ( (A)>(B) ? (A) : (B) )<br>
-<br>
-/** Minimum and maximum of three values: */<br>
-#define MIN3( A, B, C ) ((A) < (B) ? MIN2(A, C) : MIN2(B, C))<br>
-#define MAX3( A, B, C ) ((A) > (B) ? MAX2(A, C) : MAX2(B, C))<br>
-<br>
static inline unsigned<br>
minify(unsigned value, unsigned levels)<br>
{<br>
diff --git a/src/util/macros.h b/src/util/macros.h<br>
index 9dea2a0..27d1b62 100644<br>
--- a/src/util/macros.h<br>
+++ b/src/util/macros.h<br>
@@ -229,4 +229,17 @@ do { \<br>
/** Compute ceiling of integer quotient of A divided by B. */<br>
#define DIV_ROUND_UP( A, B ) ( (A) % (B) == 0 ? (A)/(B) : (A)/(B)+1 )<br>
<br>
+/** Clamp X to [MIN,MAX] */<br>
+#define CLAMP( X, MIN, MAX ) ( (X)<(MIN) ? (MIN) : ((X)>(MAX) ? (MAX) : (X)) )<br>
+<br>
+/** Minimum of two values: */<br>
+#define MIN2( A, B ) ( (A)<(B) ? (A) : (B) )<br>
+<br>
+/** Maximum of two values: */<br>
+#define MAX2( A, B ) ( (A)>(B) ? (A) : (B) )<br>
+<br>
+/** Minimum and maximum of three values: */<br>
+#define MIN3( A, B, C ) ((A) < (B) ? MIN2(A, C) : MIN2(B, C))<br>
+#define MAX3( A, B, C ) ((A) > (B) ? MAX2(A, C) : MAX2(B, C))<br>
+<br>
#endif /* UTIL_MACROS_H */<br>
<span class="HOEnZb"><font color="#888888">--<br>
2.5.5<br>
<br>
______________________________<wbr>_________________<br>
mesa-dev mailing list<br>
<a href="mailto:mesa-dev@lists.freedesktop.org">mesa-dev@lists.freedesktop.org</a><br>
<a href="https://lists.freedesktop.org/mailman/listinfo/mesa-dev" rel="noreferrer" target="_blank">https://lists.freedesktop.org/<wbr>mailman/listinfo/mesa-dev</a><br>
</font></span></blockquote></div><br></div>