mojoshader_internal.h
changeset 606 63e7a66ac320
parent 603 c7a964b1b0eb
child 611 8c2ee1a97ee1
--- a/mojoshader_internal.h	Fri Feb 13 02:28:26 2009 -0500
+++ b/mojoshader_internal.h	Fri Feb 13 02:29:17 2009 -0500
@@ -119,6 +119,11 @@
 #   define SWAP32(x) (x)
 #endif
 
+static inline int Min(const int a, const int b)
+{
+    return ((a < b) ? a : b);
+} // Min
+
 // This is the ID for a D3DXSHADER_CONSTANTTABLE in the bytecode comments.
 #define CTAB_ID 0x42415443  // 0x42415443 == 'CTAB'
 #define CTAB_SIZE 28  // sizeof (D3DXSHADER_CONSTANTTABLE).