Glade Reference
The Edge class represents an edge, i.e a connected pair of vertices.
Creates and edge object. The endpoints are undefined.
Creates and Edge object and initialises the endpoints to the two points.
Creates and Edge object and initialises the endpoints.
Gets one endpoint P0.
Gets the other endpoint P1.
sets endpoint P0 to p.
sets endpoint P1 to p.
Transposes the edge by the distance specified by dx, dy.
Returns true if the edges are the same i.e. endpoints P0 and P1 are identical.
Returns true if of the edges are not the same i.e. endpoints P0 and P1 are not identical.
Returns the Euclidian length of the edge e.
Returns true if the edge is horizontal.
Returns true if the edge is vertical.
Returns true if the edge is diagonal.
Returns true if the edge is either horizontal or vertical.
Returns the horizontal distance between the edges endpoints i.e. P1-P0.
Returns the vertical distance between the edges endpoints i.e. P1-P0.
Returns true if the point p lies on the edge e. If includeEnds is true, the point p can lie on the endpoints of the edge and be considered ' contained'.
Returns true if the edge crosses the Rect r, i.e. if the edge intersects one of the Rect's edges. If touch is true, this includes the endpoint of the edge touching an edge of the Rect.
Returns true if the edge crosses the polygon given by pts, i.e. if the edge intersects one of the polygon's edges. If touch is true, this includes the endpoint of the edge touching an edge of the polygon.
Returns the shortest distance of a point p to the edge.
Returns the shortest distance of the edge to another edge.
Returns true if the edges intersect at some point. If includeEnds is true, returns true if the edges intersect at endpoint(s).
Returns the point of intersection of two edges. The result is only valid if the edges intersect.
Returns true if the edges are colinear, i.e. the edges are parallel and a point of one edge is on the other edge.
Returns true if this edge is parallel to the other edge.
Returns true if point p is to the left of edge e, i.e. 'inside'. Note this assumes the direction of the Edge is from endpoint P0 to endpoint P1.
Returns the point on the edge that is nearest the Point pt. The point p is either on a line perpendicular to the edge, or if no such line exists, is the nearest endpoint of the edge.
Returns a Vector that is the perpendicular distance from the Point pt to the edge.
Returns true if edges E1 and E2 are parallel and project. e3 and e4 are the resulting projecting edges.
Copyright © Peardrop Design 2024.