Class DisplayClip2
- Namespace
- OpenCAD2D
- Assembly
- OpenCAD2D.Core.dll
The outline of a clipped viewport (VPCLIP): a closed ring of vertices in paper units, an edge going from a vertex to the next, an arc where the bulge of the first is not nought, as a polyline's bulge says. A circle of radius 30 is two vertices 60 apart, each with the bulge 1; an L-shape six vertices, every bulge nought. A region with a hole or of several faces adds its other rings (Others), and a point is inside where it is inside an odd number of rings, so that a ring inside the first is a hole.
public sealed class DisplayClip2
- Inheritance
-
DisplayClip2
- Inherited Members
Constructors
- DisplayClip2(double[], double[])
Makes an outline.
- DisplayClip2(double[], double[], IReadOnlyList<DisplayClip2>)
Makes an outline of several rings, as a region with a hole or of several faces has.
Properties
- Count
Gets the number of vertices of the first ring.
- Others
Gets the rings after the first, a hole or another face of the region the outline is of; none for an outline of one ring.
Methods
- Bulge(int)
Gets the bulge of the edge leaving a vertex.
- Contains(double, double)
Gets whether a point lies inside the outline, inside an odd number of its rings; a point on an edge may fall either side.
- DistanceToEdge(double, double)
Gets the distance from a point to the nearest edge of the outline, inside it or out.
- Flatten(double)
Gets the outline as a ring of straight edges, an arc cut into pieces whose chords lie no farther from it than a tolerance, so that a circle of radius 100 cut to 0.01 is a ring of about 220 points. The vertices of the outline are among the points.
- FlattenAll(double)
Gets every ring as a ring of straight edges, as Flatten(double) gives the first, the first ring first and then the others in order: the rings to fill even-odd, so that a ring inside another is a hole.
- X(int)
Gets the x of a vertex.
- Y(int)
Gets the y of a vertex.