Functions | |
void | Edit_Polygon (HC_KEY key, int offset, int ndelete, int insert, const HC_POINT *points) |
void | DEdit_Polygon (HC_KEY key, int offset, int delete, int insert, const HCD_POINT *points) |
Adjusts the boundary of a previously declared polygon.
key | - The unique identifier returned by a previous call to Insert_Polygon() . |
offset | - Number of the point in the original polygon definition just before which to start editing. "0" is the first. If specified as "-1", editing starts after the last position. |
ndelete | - Number of points to delete. |
insert | - The number of points contained in points. |
points | - Vector of x-y-z triplets to insert. (A simple N x 3 array may also be used.) Passed by reference always. |
Edit_Polygon() lets you modify a polygon with a long boundary as it sits in the database. You don't have to delete and reinsert it from scratch.
Edit_Polygon() changes the originally specified points vector (see Insert_Polygon() ), starting at offset in the vector. First ndelete points are removed, then insert points, obtained from the points vector, are inserted.
If you delete point #1 and point #2 from a polygon, the next time around the point that was "#3" will now be #1. Insertion works in a similar manner.
If you work in 3-D, make sure all the points are still coplanar. The system does not check for this and non-planar polygons result in undefined behavior.
If you originally specified the last point as your first point, the first point is considered redundant and trimmed off.
void DEdit_Polygon | ( | HC_KEY | key, |
int | offset, | ||
int | delete, | ||
int | insert, | ||
const HCD_POINT * | points | ||
) |
Similar to Edit_Polygon(), but accepts double-precision values.
key | - The unique identifier returned by a previous call to DInsert_Polygon() . |
offset | - Number of the point in the original polygon definition just before which to start editing. "0" is the first. If specified as "-1", editing starts after the last position. |
delete | - Number of points to delete. |
insert | - The number of points contained in points. |
points | - Vector of x-y-z triplets to insert. (A simple N x 3 array may also be used.) Passed by reference always. |
No additional details. See Edit_Polygon().