Edge Rewrite
// HTMLRewriter · presentation

This page was redesigned at the edge.

Cloudflare fetched the original article and streamed it through HTMLRewriter to apply an entirely new visual system without rebuilding the source page.

// request.cf · coarse context

A page that knows where it met you.

Only coarse request metadata is shown. This demo does not display or persist visitor IP addresses.

Country
US
Cloudflare location
CMH
Connection
HTTP/2
Language
Not provided

Ray ID: a22370beaa04fa14

Jump to content

// Workers AI · dad joke modeWhat did snap rounding say to the number? You're rounded up to my expectations.

From Wikipedia, the free encyclopedia

Snap rounding is a method of approximating line segment locations by creating a grid and placing each point in the centre of a cell (pixel) of the grid. The method preserves certain topological properties of the arrangement of line segments.

Drawbacks include the potential interpolation of additional vertices in line segments (lines become polylines), the arbitrary closeness of a point to a non-incident edge, and arbitrary numbers of intersections between input line-segments. The 3 dimensional case is worse, with a polyhedral subdivision of complexity n becoming complexity O(n4).

There are more refined algorithms to cope with some of these issues, for example iterated snap rounding guarantees a "large" separation between points and non-incident edges.[1]

Algorithm

[edit]

... (please edit). See,[2] [3] and https://www.cgal.org/ ([4][5])

Properties

[edit]
  • Canonicity:
  • Efficiency; A number of efficient implementations exist.

Conversely there are undesirable properties:

See also

[edit]

References

[edit]
  1. Csaba D. Toth; Joseph O'Rourke; Jacob E. Goodman (13 April 2004). Handbook of Discrete and Computational Geometry, Second Edition. CRC Press. pp. 552–. ISBN 978-1-4200-3531-5.
  2. L. J. Guibas; D. H. Marimont (1998). "Rounding arrangements dynamically". Int. J. Comput. Geom. Appl. 8 (2): 157–176. doi:10.1142/S0218195998000096.
  3. Efficient Snap-Rounding with Integer Arithmetic, Binay K. Bhattacharya and Jeff Sember
  4. CGAL Guide https://doc.cgal.org/latest/Snap_rounding_2/index.html
  5. CGAL Implementation https://doc.cgal.org/latest/Snap_rounding_2/group__PkgSnapRounding2Ref.html