Skip to content

Improve accuracy of boolean operations

PBS requested to merge pbs3141/inkscape:boolops-accuracy into master

This MR improves the accuracy of the shape builder / boolean operations in two main ways: a per-segment rather than a per-shape subdivision threshold, and pre-processing of the intersections using lib2geom. The MR is correspondingly split into two commits, plus a preliminary refactoring commit.

The first of these changes allows seamless re-unions, i.e. pieces that were generated during a previous boolean operation can now be joined together most of the time without artifacts:

image

The second change improves the accuracy of the geometry by computing intersections to much higher precision, which gets rid of #4453:

inters-cmp

I'd like to fix the other issues (e.g. #4477 and #4733), but that wasn't possible with these rather minor modifications. That will take some heftier rewriting and redesigning. Hopefully this MR will enable livarot to work acceptably well in the meantime.

Fixes #612, #2875, #3265, #3543, #4453.

Edited by PBS

Merge request reports