EXPERIMENTAL_HIGH_PRECISION_MATH_Q3MAP2_FIXES ->
Q3MAP2_EXPERIMENTAL_HIGH_PRECISION_MATH_FIXES
EXPERIMENTAL_SNAP_NORMAL_FIX ->
Q3MAP2_EXPERIMENTAL_SNAP_NORMAL_FIX
EXPERIMENTAL_SNAP_PLANE_FIX ->
Q3MAP2_EXPERIMENTAL_SNAP_PLANE_FIX
git-svn-id: svn://svn.icculus.org/gtkradiant/GtkRadiant/trunk@423
8a3a26a2-13c4-0310-b231-
cf6edde360e5
qboolean CreateBrushWindings( brush_t *brush )
{
int i, j;
-#if EXPERIMENTAL_HIGH_PRECISION_MATH_Q3MAP2_FIXES
+#if Q3MAP2_EXPERIMENTAL_HIGH_PRECISION_MATH_FIXES
winding_accu_t *w;
#else
winding_t *w;
plane = &mapplanes[ side->planenum ];
/* make huge winding */
-#if EXPERIMENTAL_HIGH_PRECISION_MATH_Q3MAP2_FIXES
+#if Q3MAP2_EXPERIMENTAL_HIGH_PRECISION_MATH_FIXES
w = BaseWindingForPlaneAccu(plane->normal, plane->dist);
#else
w = BaseWindingForPlane( plane->normal, plane->dist );
if( brush->sides[ j ].bevel )
continue;
plane = &mapplanes[ brush->sides[ j ].planenum ^ 1 ];
-#if EXPERIMENTAL_HIGH_PRECISION_MATH_Q3MAP2_FIXES
+#if Q3MAP2_EXPERIMENTAL_HIGH_PRECISION_MATH_FIXES
ChopWindingInPlaceAccu(&w, plane->normal, plane->dist, 0);
#else
ChopWindingInPlace( &w, plane->normal, plane->dist, 0 ); // CLIP_EPSILON );
#endif
/* ydnar: fix broken windings that would generate trifans */
-#if EXPERIMENTAL_HIGH_PRECISION_MATH_Q3MAP2_FIXES
+#if Q3MAP2_EXPERIMENTAL_HIGH_PRECISION_MATH_FIXES
// I think it's better to FixWindingAccu() once after we chop with all planes
// so that error isn't multiplied. There is nothing natural about welding
// the points unless they are the final endpoints. ChopWindingInPlaceAccu()
}
/* set side winding */
-#if EXPERIMENTAL_HIGH_PRECISION_MATH_Q3MAP2_FIXES
+#if Q3MAP2_EXPERIMENTAL_HIGH_PRECISION_MATH_FIXES
if (w != NULL)
{
FixWindingAccu(w);
qboolean SnapNormal( vec3_t normal )
{
-#if EXPERIMENTAL_SNAP_NORMAL_FIX
+#if Q3MAP2_EXPERIMENTAL_SNAP_NORMAL_FIX
int i;
qboolean adjusted = qfalse;
vec_t d;
-#if EXPERIMENTAL_SNAP_PLANE_FIX
+#if Q3MAP2_EXPERIMENTAL_SNAP_PLANE_FIX
SnapPlaneImproved(normal, &dist, numPoints, (const vec3_t *) points);
#else
SnapPlane( normal, &dist );
int i;
plane_t *p;
-#if EXPERIMENTAL_SNAP_PLANE_FIX
+#if Q3MAP2_EXPERIMENTAL_SNAP_PLANE_FIX
SnapPlaneImproved(normal, &dist, numPoints, (const vec3_t *) points);
#else
SnapPlane( normal, &dist );
int MapPlaneFromPoints( vec3_t *p )
{
-#if EXPERIMENTAL_HIGH_PRECISION_MATH_Q3MAP2_FIXES
+#if Q3MAP2_EXPERIMENTAL_HIGH_PRECISION_MATH_FIXES
vec3_accu_t paccu[3];
vec3_accu_t t1, t2, normalAccu;
vec3_t normal;
/* temporary hacks and tests (please keep off in SVN to prevent anyone's legacy map from screwing up) */
/* 2011-01-10 TTimo says we should turn these on in SVN, so turning on now */
-#define EXPERIMENTAL_HIGH_PRECISION_MATH_Q3MAP2_FIXES 1
-#define EXPERIMENTAL_SNAP_NORMAL_FIX 1
-#define EXPERIMENTAL_SNAP_PLANE_FIX 1
+#define Q3MAP2_EXPERIMENTAL_HIGH_PRECISION_MATH_FIXES 1
+#define Q3MAP2_EXPERIMENTAL_SNAP_NORMAL_FIX 1
+#define Q3MAP2_EXPERIMENTAL_SNAP_PLANE_FIX 1
/* general */
#define MAX_QPATH 64
Q_EXTERN qboolean debugInset Q_ASSIGN( qfalse );
Q_EXTERN qboolean debugPortals Q_ASSIGN( qfalse );
-#if EXPERIMENTAL_SNAP_NORMAL_FIX
+#if Q3MAP2_EXPERIMENTAL_SNAP_NORMAL_FIX
// Increasing the normalEpsilon to compensate for new logic in SnapNormal(), where
// this epsilon is now used to compare against 0 components instead of the 1 or -1
// components. Unfortunately, normalEpsilon is also used in PlaneEqual(). So changing
Q_EXTERN double normalEpsilon Q_ASSIGN( 0.00001 );
#endif
-#if EXPERIMENTAL_HIGH_PRECISION_MATH_Q3MAP2_FIXES
+#if Q3MAP2_EXPERIMENTAL_HIGH_PRECISION_MATH_FIXES
// NOTE: This distanceEpsilon is too small if parts of the map are at maximum world
// extents (in the range of plus or minus 2^16). The smallest epsilon at values
// close to 2^16 is about 0.007, which is greater than distanceEpsilon. Therefore,