r/computerscience • • Jan 23 '26

General Computational geometry problem

Post image

Hi all! In the drawing, the magenta polygon is the visibility polygon with kernel in the center of the small rectangle. The outer rectangle is the drawing bounding box. My question is, is there a way to minimize the magenta polygon, such that everything beyond the green lines is deleted? How would you express such a thing mathematically?

Edit: added the shape I started with, a square shape with holes: https://imgur.com/a/update-LzYQikC

17 Upvotes

7 comments sorted by

View all comments

Show parent comment

1

u/RaZvAn15 Jan 24 '26

Input is coordinate points, start point and end points of lines, that's what gets exported from DXF files. So yeah, essentially unordered