Skip to content

Latest commit

 

History

History
19 lines (15 loc) · 800 Bytes

File metadata and controls

19 lines (15 loc) · 800 Bytes

TraversalSplitter

This is a haxe implementation of an algorithm that partitions orthogonal polygons into several small rectangular areas. A more detailed description about the algorithm can be found on my blog.

AlgorithmRundown

  1. traverse the polygon clockwise and find vertices with counterclockwise rotation
  2. split the graph from those vertices to any direction
  3. pick a vertex and traverse the adjusted graph clockwise to build your rectangle

runtime:

  • multiple platform targets supported
  • simple input / output interface

development-time:

  • confusing line intersection algorithm
  • monster class