mirror of
https://github.com/Nexoniarz/Fry3DX.git
synced 2026-11-03 12:34:27 +00:00
From Blender and Maya: soft selection in shape editing (Shift+O; near points follow, the wheel while dragging sets how far), push out / pull in along normals (Alt+S), smooth points, bridge two faces with a tunnel, show only the selected (/ or Shift+H); fry_shapeop for scripts and tests; tests
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
parent
3bcd50033d
commit
3f23371eac
4 changed files with 268 additions and 6 deletions
11
src/mesh.h
11
src/mesh.h
|
|
@ -131,6 +131,17 @@ std::set<int> linkedVerts(const Mesh& m, const std::set<int>& verts);
|
|||
// The points next to these (by an edge), and these.
|
||||
std::set<int> growVerts(const Mesh& m, const std::set<int>& verts);
|
||||
|
||||
// Points moved towards their neighbours' middle (`amount` 0..1, a few times for more): bumps
|
||||
// evened out (Blender's Smooth Vertices, Maya's Average Vertices).
|
||||
void smoothPoints(Mesh& m, const std::set<int>& verts, float amount = 0.5f, int times = 1);
|
||||
// Points pushed out along the surface's normal there (negative: pulled in): fatter or thinner,
|
||||
// keeping the shape (Blender's Shrink/Fatten).
|
||||
void pushPoints(Mesh& m, const std::set<int>& verts, float distance);
|
||||
// Two faces with as many corners each taken out and joined by a tunnel of faces between their
|
||||
// edges, each corner to the nearest one round (Bridge, as in Blender and Maya). The new faces;
|
||||
// empty (and nothing changed) if they aren't two faces with as many corners.
|
||||
std::vector<int> bridgeFaces(Mesh& m, int a, int b);
|
||||
|
||||
// ── Whole shapes ──
|
||||
|
||||
// Faces next to each other lying flat together (normals within `angle` degrees) joined into
|
||||
|
|
|
|||
Loading…
Reference in a new issue