Blender Addon: Boundaries to Ngon
This tool provides a one-click solution to fill non-intersecting edge loops with a small set of ngons. It extends Blender's built-in Fill tool by correctly handling holes and nested polygons. Since the tool also accepts faces as input, it serves as an advanced "Dissolve Faces" tool.
Tested for Blender 3.5+ on Windows. In theory it should work on Mac (M1+), but I haven't tested it myself.
For other system architectures, the Addon falls back to a numpy-based implementation of delauny triangulation. This is indicated in the "Preferences"-Panel. This fallback may cause some glitchy Ngons in case of challenging geometry.
How to use:
- Enter Edit Mode.
- Select the boundary edges you want to fill.
- Optionally select faces to include their boundary edges (edges with exactly one adjacent selected face will be filled).
- Click "Create Ngons".
Key Features
Smart hole handling: Correctly processes holes by connecting them to outer polygons, creating 2+ ngons. Works with nested polygons ("holes within holes") and complex cases with hundreds of input edges.
Advanced face dissolution: Since you can input faces, this serves as an enhanced "Dissolve Faces" tool that properly handles holes.
Optimized ngon count: The algorithm minimizes the number of output ngons (typically just 2 ngons for standard cases). Complex scenarios may produce significantly more due to the computational complexity of this optimization problem.
Point weld support: Handles cases where two polygons touch at exactly one vertex, treating them as external polygons or holes based on their relative position.
Flatten option: Projects inner vertices to be roughly coplanar with outer vertices.
UV preservation: Maintains UV coordinates when desired, using projection matrices estimated from input faces.
Best Practices
To work properly,
- each edge must belong to exactly one closed loop, and
- no two edges should intersect on the projection plane
The algorithm projects 3D points to a 2D plane, working best when edges are roughly coplanar. Four projection methods are available to handle difficult cases:
- Simple: Assumes full coplanarity; determines projection plane from first 3 selected vertices
- Linear Approximation: Estimates plane from all selected vertices using SVD
- Active Face: Uses the active face's plane for projection
- From Object: Averages all faces from a selected mesh object to construct the projection plane
Note: Incorrect projections may cause edge intersections, resulting in degenerate ngons.
Performance
The algorithm is mostly written in python, which is fine for a few hundred edges as input. For very large dataset, expect poor performance. You can adjust the maximum number of iterations used by the algorithm in the preferences.