Inheritance diagram for oaPointArray:
Public Methods | |
oaPointArray (oaUInt4 sizeIn=0) | |
oaPointArray (const oaPointArray &pointsIn) | |
oaPointArray (const oaPointArray &pointsIn, const oaTransform &xform) | |
oaPointArray (const oaPointArray &pointsIn, const oaPoint &offset) | |
oaPointArray (const oaPoint pointsIn[], oaUInt4 numPointsIn) | |
oaPointArray (const oaBox &rectIn) | |
oaBoolean | isSelfIntersecting (oaBoolean isClosed=true) const |
oaBoolean | isOrthogonal (oaBoolean isClosed=true) const |
oaBoolean | isRectangle () const |
oaBoolean | onEdge (const oaPoint &point, oaBoolean isClosed=true) const |
oaBoolean | contains (const oaPoint &point, oaBoolean includeEdges=true) const |
oaBoolean | contains (const oaBox &box) const |
oaBoolean | overlaps (const oaBox &box, oaBoolean closed=true) const |
oaDouble | distanceFrom2 (const oaPoint &point) const |
oaDouble | getArea () const |
oaBoolean | hasExtraPoints (oaBoolean isClosed=true) const |
void | compress (oaPointArray &pointsOut, oaBoolean isClosed=true) const |
void | compress (oaBoolean isClosed=true) |
void | transform (const oaTransform &xform, oaPointArray &result) const |
void | transform (const oaTransform &xform) |
void | transform (const oaPoint &offset, oaPointArray &result) const |
void | transform (const oaPoint &offset) |
void | transform (oaDouble scale, oaDouble angle, oaPointArray &result) const |
void | transform (oaDouble scale, oaDouble angle) |
void | getBBox (oaBox &bBox) const |
Friends | |
class | oaUndoData |
PointArrays can be used either to indicate a closed figure, such as a polygon, or an open set of points such as a line. When used to describe a closed figure, the connection between the first and last point is always implicit. In such usage it is an error to have the first and last point be the same. Some member functions of oaPointArray have an isClosed flag to indicate whether the array is intended to describe a closed figure or an open line. Many functions that use PointArrays only apply to closed figures, and a flag is not needed for these functions.
PointArrays used as arguments to member functions of oaFig classes should always be well-formed such that they do not contain duplicate or collinear points. oaPointArray::compress() can be used to remove such points from the array.
Like all oaArray classes, oaPointArrays have separate counts for their allocated size and for the number of elements currently in use. For good performance be sure to avoid small incremental allocations as elements are added to an array.
|
This function constructs an oaPointArray object and allocates storage for as many points as specified by numPoints. |
|
This function constructs an oaPointArray object, creating a copy of the specified pointArray. |
|
This function constructs an oaPointArray object, creating a copy of the specified pointArray after it is transformed using the specified xform oaTransform. |
|
This function constructs an oaPointArray object, creating a copy of the specified pointArray, and applying an offset contained in the specified oaPoint object. |
|
This function constructs an oaPointArray object by copying in an array of oaPoint. The number of elements in the array is indicated by numPointsIn. |
|
This oaPointArray constructor function creates an array consisting of the four corners of the specified rectIn rectangle, starting at the lower-left and moving clockwise.
|
|
This function removes all collinear and coincident points from this oaPointArray. An oaPointArray contains coincident points if two adjacent points are identical. An oaPointArray contains collinear points if three adjacent points lie on the same line. For closed oaPointArrays (isClosed = true), the first and last point are considered adjacent. The result of this function is not valid for oaPointArrays containing two adjacent edges that overlap. Such oaPointArrays are considered illegal for use in figures. Note: compress() will produce incorrect results if the edges connected by the points in the point array cross.
|
|
This function returns in pointsOut the point array that is created by removing all collinear and coincident points from this oaPointArray. The result of this function is not valid for oaPointArrays containing two adjacent edges that overlap. Such oaPointArrays are considered illegal for use in figures. Note: compress() will produce incorrect results if the edges connected by the points in the point array cross.
|
|
This function returns a boolean indicating whether or not this pointArray, which is assumed to be closed, contains the specified oaBox.
|
|
This function returns a boolean indicating whether or not the specified point is inside or on the edge of this pointArray. Note: the point array is assumed to be closed--that is, the first and last points in the array are treated as connected.
|
|
This function returns the square of the distance from the specified point to the closest point on this oaPointArray. Note: the point array is assumed to be closed--that is, the first and last points in the array are treated as connected. |
|
This function returns the area in DBUU contained by the oaPointArray. The PointArray is assumed to be closed. Note: The points in the array can either be a clockwise or a counter-clockwise enclosure. However they must not be self-intersecting. |
|
This function calculates the bounding box of the points in this oaPointArray. |
|
This function returns true if this pointArray has any collinear or coincident points. Also returns true if isClosed = true (see below) and the last and first points of the array specify the same point.
|
|
This function returns a boolean value that indicates if all of the angles in this oaPointArray are multiples of 90 degrees.
|
|
This function returns true if this oaPointArray describes a rectangle that could be created as an oaRect. Specifically, to return true the point array must have four points after collinear and coincident points have been removed, and those points must be the corners of a rectangle with horizontal and vertical sides. |
|
This function returns a boolean value that indicates if this oaPointArray intersects itself. This does not include self-touching oaPointArrays.
|
|
This function returns a boolean value that indicates if the specified point is on this oaPointArray.
|
|
This function returns a boolean value that indicates if the specified box overlaps or touches this oaPointArray. Note: overlaps() assumes that the points in the array are specified in clockwise order.
|
|
This function transforms this oaPointArray by the specified scale factor and rotation angle. The points are rotated about the origin. |
|
This function transforms this oaPointArray by the specified scale factor and rotation angle. The points are rotated about the origin. The result is stored in result, which can be the same point. |
|
This function transforms this oaPointArray with the specified offset. |
|
This function transforms this oaPointArray with the specified offset and stores the result in result, which can be the same oaPointArray. The result is assumed the same size as the pointArray. |
|
This function transforms this oaPointArray with the specified transform. |
|
This function transforms this oaPointArray with the specified transform and stores the result in result, which can be the same oaPointArray. The result is assumed the same size as the oaPointArray. |
|
|
Copyright © 2002 - 2010 Cadence Design Systems, Inc.
All Rights Reserved.