00001 #ifndef _SIMPLEDEFS_H_ 00002 #define _SIMPLEDEFS_H_ 00003 00004 #include <math.h> 00005 00006 #define TOLERANCE 0.0001 00007 #define SNAPTOZERO(t) ( ((t)>0.0f) ? ( ((t)<TOLERANCE) ? (0.0f) : (t) ) : ( ((t)>-TOLERANCE) ? (0.0f) : (t)) ) 00008 00009 #define ROOT_TWO 1.4142135623730950488016887242097 00010 00011 #define OVER_3 0.33333333 00012 #define OVER_6 0.16666666 00013 #define OVER_12 0.0833333333 00014 #define OVER_2_3 0.6666666666 00015 00016 #endif