mirror of
https://github.com/hannobraun/Fornjot
synced 2025-01-30 11:55:57 +00:00
Set half-edge geometry in SplitEdge
This commit is contained in:
parent
5b8ae052c6
commit
2bacac3a73
@ -3,8 +3,8 @@ use fj_math::Point;
|
|||||||
use crate::{
|
use crate::{
|
||||||
objects::{HalfEdge, Shell},
|
objects::{HalfEdge, Shell},
|
||||||
operations::{
|
operations::{
|
||||||
derive::DeriveFrom, insert::Insert, replace::ReplaceHalfEdge,
|
derive::DeriveFrom, geometry::UpdateHalfEdgeGeometry, insert::Insert,
|
||||||
split::SplitHalfEdge, update::UpdateHalfEdge,
|
replace::ReplaceHalfEdge, split::SplitHalfEdge, update::UpdateHalfEdge,
|
||||||
},
|
},
|
||||||
queries::SiblingOfHalfEdge,
|
queries::SiblingOfHalfEdge,
|
||||||
storage::Handle,
|
storage::Handle,
|
||||||
@ -55,10 +55,21 @@ impl SplitEdge for Shell {
|
|||||||
)
|
)
|
||||||
.insert(core);
|
.insert(core);
|
||||||
[sibling_a, sibling_b].map(|half_edge| {
|
[sibling_a, sibling_b].map(|half_edge| {
|
||||||
half_edge.insert(core).derive_from(&sibling, core)
|
half_edge.insert(core).derive_from(&sibling, core).set_path(
|
||||||
|
core.layers.geometry.of_half_edge(&sibling).path,
|
||||||
|
&mut core.layers.geometry,
|
||||||
|
)
|
||||||
})
|
})
|
||||||
};
|
};
|
||||||
|
|
||||||
|
let [half_edge_a, half_edge_b] =
|
||||||
|
[half_edge_a, half_edge_b].map(|half_edge_part| {
|
||||||
|
half_edge_part.set_path(
|
||||||
|
core.layers.geometry.of_half_edge(half_edge).path,
|
||||||
|
&mut core.layers.geometry,
|
||||||
|
)
|
||||||
|
});
|
||||||
|
|
||||||
let shell = self
|
let shell = self
|
||||||
.replace_half_edge(
|
.replace_half_edge(
|
||||||
half_edge,
|
half_edge,
|
||||||
|
Loading…
Reference in New Issue
Block a user