Main Page Class Hierarchy Compound List File List Compound Members
iClipper2D Struct Reference This interfaces represents a 2D clipper for polygons.
More...
#include <clip2d.h >
Inheritance diagram for iClipper2D:
List of all members.
Public Methods
virtual uint8 Clip (csVector2 *InPolygon, int InCount, csVector2 *OutPolygon, int &OutCount)=0
Clip a set of 2D points and return in 'OutPolygon' which is expected to contain space at least for MAX_OUTPUT_VERTICES elements. More...
virtual uint8 Clip (csVector2 *InPolygon, int InCount, csVector2 *OutPolygon, int &OutCount, csBox2 &BoundingBox)=0
Clip a set of 2D points. More...
virtual uint8 Clip (csVector2 *InPolygon, int InCount, csVector2 *OutPolygon, int &OutCount, csVertexStatus *OutStatus)=0
Same as above but provides additional information on each output vertex. More...
virtual uint8 ClipInPlace (csVector2 *InPolygon, int &InOutCount, csBox2 &BoundingBox)=0
Wrapper function: clip a polygon in-place.
virtual int ClassifyBox (const csBox2 &box)=0
Classify some bounding box against this clipper. More...
virtual bool IsInside (const csVector2 &v)=0
Return true if given point is inside (or on bound) of clipper polygon.
virtual int GetVertexCount ()=0
Return number of vertices for this clipper polygon.
virtual csVector2 * GetClipPoly ()=0
Return a pointer to the array of csVector2 's.
Detailed Description
This interfaces represents a 2D clipper for polygons.
Member Function Documentation
int iClipper2D::ClassifyBox (
const csBox2 & box ) [pure virtual]
Classify some bounding box against this clipper.
This function returns:
-1 if box is not visible. 0 if box is partially visible. 1 if box is entirely visible.
Reimplemented in csBoxClipper , and csPolygonClipper .
Same as above but provides additional information on each output vertex.
The information type can be: vertex is one of original vertices, vertex is on the edge of the original polygon and vertex is arbitrary located inside the original polygon. Both OutPolygon and OutStatus arrays are expected to have enough storage for at least MAX_OUTPUT_VERTICES elements.
Reimplemented in csBoxClipper , and csPolygonClipper .
uint8 iClipper2D::Clip (
csVector2 * InPolygon ,
int InCount ,
csVector2 * OutPolygon ,
int & OutCount ,
csBox2 & BoundingBox ) [pure virtual]
Clip a set of 2D points.
On output Count is set to number of vertices in output polygon. The output array is expected to contain space for at least MAX_OUTPUT_VERTICES elements. The bounding box is set to the minimal rectangle that contains the output polygon. Returns one of CS_CLIP_XXX values defined above.
Reimplemented in csBoxClipper , and csPolygonClipper .
uint8 iClipper2D::Clip (
csVector2 * InPolygon ,
int InCount ,
csVector2 * OutPolygon ,
int & OutCount ) [pure virtual]
Clip a set of 2D points and return in 'OutPolygon' which is expected to contain space at least for MAX_OUTPUT_VERTICES elements.
Returns one of CS_CLIP_XXX values defined above.
Reimplemented in csBoxClipper , and csPolygonClipper .
The documentation for this struct was generated from the following file:
Generated for Crystal Space by
doxygen
1.2.5 written by
Dimitri van Heesch ,
©1997-2000