Polygon edge clipping
First Claim
1. A method for clipping a convex source polygon to a view-window defined by boundary edges for forming a clipped figure, wherein a respective boundary edge plane coinciding with each boundary edge of the view window is predeterminedly defined, comprising:
- determining intersection points between edges of the source polygon and boundary edges of the view window while proceeding from a randomly selected vertex of the source polygon in a predetermined direction around the perimeter of the source polygon;
assigning each intersection point determined as either an entry point to, or an exit point from, the view window in response to the predetermined direction along the edge of the source polygon forming the respective intersection point;
sequentially supplying as encountered in the predetermined direction around the perimeter of the source polygon;
source polygon edges that lie entirely within the view window, valid portions of source polygon edges that include an exit point and/or an entry point, and a valid portion of the boundary edges of the view window from an exit point to the next determined entry point before supplying the valid portion of the source polygon edge that includes the next determined entry point; and
substituting the value of the first entry point determined for the value of the next determined entry point when a last exit point assigned does not include a corresponding next determined entry point after the step of determining has returned to the randomly selected vertex,wherein the step of sequentially supplying is performed while the edges of the clipped figure are being determined without having to recall the valid portion of the edge of the source polygon and the portion of the boundary edges of the view window from the first determined exit point to the entry point next determined.
5 Assignments
0 Petitions
Accused Products
Abstract
A method for clipping a source polygon to a view window permits the valid (i.e. potentially visible) edges or portions of edges of the source polygon and of the view window boundary edges to be sequentially output for further processing, while determining the valid parts in a predetermined direction around the perimeter of the source polygon, without having to store (other than for a first entry point) the value of exit points from or entry points to the view window. Only an end point of an edge of the source polygon is considered at a time so that a maximum of two intersection point determinations between the source polygon edge and view window boundary planes outside of which the source polygon edge lies are required to ascertain if a portion of the source polygon edge is valid.
-
Citations
12 Claims
-
1. A method for clipping a convex source polygon to a view-window defined by boundary edges for forming a clipped figure, wherein a respective boundary edge plane coinciding with each boundary edge of the view window is predeterminedly defined, comprising:
-
determining intersection points between edges of the source polygon and boundary edges of the view window while proceeding from a randomly selected vertex of the source polygon in a predetermined direction around the perimeter of the source polygon; assigning each intersection point determined as either an entry point to, or an exit point from, the view window in response to the predetermined direction along the edge of the source polygon forming the respective intersection point; sequentially supplying as encountered in the predetermined direction around the perimeter of the source polygon;
source polygon edges that lie entirely within the view window, valid portions of source polygon edges that include an exit point and/or an entry point, and a valid portion of the boundary edges of the view window from an exit point to the next determined entry point before supplying the valid portion of the source polygon edge that includes the next determined entry point; andsubstituting the value of the first entry point determined for the value of the next determined entry point when a last exit point assigned does not include a corresponding next determined entry point after the step of determining has returned to the randomly selected vertex, wherein the step of sequentially supplying is performed while the edges of the clipped figure are being determined without having to recall the valid portion of the edge of the source polygon and the portion of the boundary edges of the view window from the first determined exit point to the entry point next determined. - View Dependent Claims (2, 3, 4, 5, 6, 7)
-
-
8. A method for forming a clipped figure from the interaction between a convex source polygon and a view window defined by boundary edges, wherein a respective boundary plane corresponding to each boundary edge so that the window lies inside each boundary plane, comprising:
-
determining a valid portion of edges of the source polygon in a predetermined direction around the perimeter of the source polygon that form a part of the perimeter of the clipped figure; identifying in response to the valid portion of edges of the source polygon a derived portion of the boundary edges that forms another part of the perimeter of the clipped figure; and providing the valid portion and the derived portion so that the perimeter of the clipped figure may be sequentially defined in a predetermined direction along the perimeter of the clipped figure by adjoining valid and derived portions such that the derived portion lying between an exit intersection point of the valid portion and a next determined entry intersection point of the valid portion may be provided before determining the valid portion following the next determined entry intersection point. - View Dependent Claims (9)
-
-
10. A method for clipping a convex source polygon to a view window for forming a clipped figure, wherein the view window is defined by boundary edges and a respective boundary edge plane coinciding with each boundary edge, each boundary edge plane dividing space into an inside region and an outside region disposed on opposite sides of each boundary plane and the view window further disposed in the inside region of each boundary edge plane, for each consecutive edge encountered in a predetermined direction around the perimeter of the source polygon from a predetermined vertex of the source polygon wherein each edge of the source polygon includes a first end point (V1) and a second end point (V2), the method comprising:
-
(a) disregarding the source polygon edge from further consideration when the points V1 and V2 lie in the outside region of the same boundary plane; (b) determining an alpha intersection point of the source polygon edge with the first boundary plane encountered outside of which V1 lies when proceeding from V1 to V2 ; (c) coding the alpha intersection point as an entry point and replacing the value of V1 with the value of the alpha intersection point when the alpha intersection point lies on a boundary edge of the view window; (d) disregarding the source polygon edge from further consideration when the alpha intersection point and V2 lie in the outside region of the same boundary plane; (e) determining a beta intersection point of the source polygon edge with the second boundary plane encountered outside of which the alpha intersection point lies when proceeding from the alpha intersection point to V2 whenever the alpha intersection point and V2 do not lie in the outside region of the same boundary plane and the alpha intersection point does not lie on a boundary edge of the view window; (f) disregarding the source polygon edge from further consideration when the beta intersection point does not lie on a boundary edge of the view window; (g) coding the beta intersection point as an entry point and replacing the value of the alpha intersection point with the value of the beta intersection point when the beta intersection point lies on a boundary edge of the view window; (h) coding a gamma intersection point of the source polygon edge with the first boundary plane encountered when proceeding from V1 to V2 as an exit point and replacing the value of V2 with the value of the gamma intersection point whenever V1, the alpha intersection point or the beta intersection point lies within the view window and V2 lies outside a boundary plane; (i) deriving the valid portion of the boundary edges of the view window that form a portion of the perimeter of the clipped figure from a gamma intersection point and the next determined alpha or beta intersection point coded as an entry point; and (j) sequentially providing the valid portion of the source polygon edges and the valid portion of the boundary edges of the view window for forming contiguous portions of the perimeter of the clipped figure while the alpha, beta and gamma intersections are being determined. - View Dependent Claims (11, 12)
-
Specification