-/*\r
-Copyright (C) 1999-2007 id Software, Inc. and contributors.\r
-For a list of contributors, see the accompanying CONTRIBUTORS file.\r
-\r
-This file is part of GtkRadiant.\r
-\r
-GtkRadiant is free software; you can redistribute it and/or modify\r
-it under the terms of the GNU General Public License as published by\r
-the Free Software Foundation; either version 2 of the License, or\r
-(at your option) any later version.\r
-\r
-GtkRadiant is distributed in the hope that it will be useful,\r
-but WITHOUT ANY WARRANTY; without even the implied warranty of\r
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the\r
-GNU General Public License for more details.\r
-\r
-You should have received a copy of the GNU General Public License\r
-along with GtkRadiant; if not, write to the Free Software\r
-Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA\r
-*/\r
-\r
-\r
-\r
-\r
-//returns true if the planes are equal\r
-int Plane_Equal(plane_t *a, plane_t *b, int flip);\r
-//returns false if the points are colinear\r
-int Plane_FromPoints(vec3_t p1, vec3_t p2, vec3_t p3, plane_t *plane);\r
-//returns true if the points are equal\r
-int Point_Equal(vec3_t p1, vec3_t p2, float epsilon);\r
-\r
-//allocate a winding\r
-winding_t* Winding_Alloc(int points);\r
-//free the winding\r
-void Winding_Free(winding_t *w);\r
-//create a base winding for the plane\r
-winding_t* Winding_BaseForPlane (plane_t *p);\r
-//make a winding clone\r
-winding_t* Winding_Clone(winding_t *w );\r
-//creates the reversed winding\r
-winding_t* Winding_Reverse(winding_t *w);\r
-//remove a point from the winding\r
-void Winding_RemovePoint(winding_t *w, int point);\r
-//inserts a point to a winding, creating a new winding\r
-winding_t* Winding_InsertPoint(winding_t *w, vec3_t point, int spot);\r
-//returns true if the planes are concave\r
-int Winding_PlanesConcave(winding_t *w1, winding_t *w2,\r
- vec3_t normal1, vec3_t normal2,\r
- float dist1, float dist2);\r
-//returns true if the winding is tiny\r
-int Winding_IsTiny(winding_t *w);\r
-//returns true if the winding is huge\r
-int Winding_IsHuge(winding_t *w);\r
-//clip the winding with the plane\r
-winding_t* Winding_Clip(winding_t *in, plane_t *split, qboolean keepon);\r
-//split the winding with the plane\r
-void Winding_SplitEpsilon(winding_t *in, vec3_t normal, double dist, \r
- vec_t epsilon, winding_t **front, winding_t **back);\r
-//try to merge the windings, returns the new merged winding or NULL\r
-winding_t *Winding_TryMerge(winding_t *f1, winding_t *f2, vec3_t planenormal, int keep);\r
-//create a plane for the winding\r
-void Winding_Plane(winding_t *w, vec3_t normal, double *dist);\r
-//returns the winding area\r
-float Winding_Area(winding_t *w);\r
-//returns the bounds of the winding\r
-void Winding_Bounds(winding_t *w, vec3_t mins, vec3_t maxs);\r
-//returns true if the point is inside the winding\r
-int Winding_PointInside(winding_t *w, plane_t *plane, vec3_t point, float epsilon);\r
-//returns true if the vector intersects with the winding\r
-int Winding_VectorIntersect(winding_t *w, plane_t *plane, vec3_t p1, vec3_t p2, float epsilon);\r
+/*
+ Copyright (C) 1999-2007 id Software, Inc. and contributors.
+ For a list of contributors, see the accompanying CONTRIBUTORS file.
+
+ This file is part of GtkRadiant.
+
+ GtkRadiant is free software; you can redistribute it and/or modify
+ it under the terms of the GNU General Public License as published by
+ the Free Software Foundation; either version 2 of the License, or
+ (at your option) any later version.
+
+ GtkRadiant is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU General Public License for more details.
+
+ You should have received a copy of the GNU General Public License
+ along with GtkRadiant; if not, write to the Free Software
+ Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
+ */
+
+
+
+
+//returns true if the planes are equal
+int Plane_Equal( plane_t *a, plane_t *b, int flip );
+//returns false if the points are colinear
+int Plane_FromPoints( vec3_t p1, vec3_t p2, vec3_t p3, plane_t *plane );
+//returns true if the points are equal
+int Point_Equal( vec3_t p1, vec3_t p2, float epsilon );
+
+//allocate a winding
+winding_t* Winding_Alloc( int points );
+//free the winding
+void Winding_Free( winding_t *w );
+//create a base winding for the plane
+winding_t* Winding_BaseForPlane( plane_t *p );
+//make a winding clone
+winding_t* Winding_Clone( winding_t *w );
+//creates the reversed winding
+winding_t* Winding_Reverse( winding_t *w );
+//remove a point from the winding
+void Winding_RemovePoint( winding_t *w, int point );
+//inserts a point to a winding, creating a new winding
+winding_t* Winding_InsertPoint( winding_t *w, vec3_t point, int spot );
+//returns true if the planes are concave
+int Winding_PlanesConcave( winding_t *w1, winding_t *w2,
+ vec3_t normal1, vec3_t normal2,
+ float dist1, float dist2 );
+//returns true if the winding is tiny
+int Winding_IsTiny( winding_t *w );
+//returns true if the winding is huge
+int Winding_IsHuge( winding_t *w );
+//clip the winding with the plane
+winding_t* Winding_Clip( winding_t *in, plane_t *split, qboolean keepon );
+//split the winding with the plane
+void Winding_SplitEpsilon( winding_t *in, vec3_t normal, double dist,
+ vec_t epsilon, winding_t **front, winding_t **back );
+//try to merge the windings, returns the new merged winding or NULL
+winding_t *Winding_TryMerge( winding_t *f1, winding_t *f2, vec3_t planenormal, int keep );
+//create a plane for the winding
+void Winding_Plane( winding_t *w, vec3_t normal, double *dist );
+//returns the winding area
+float Winding_Area( winding_t *w );
+//returns the bounds of the winding
+void Winding_Bounds( winding_t *w, vec3_t mins, vec3_t maxs );
+//returns true if the point is inside the winding
+int Winding_PointInside( winding_t *w, plane_t *plane, vec3_t point, float epsilon );
+//returns true if the vector intersects with the winding
+int Winding_VectorIntersect( winding_t *w, plane_t *plane, vec3_t p1, vec3_t p2, float epsilon );