mirror of
https://github.com/hannobraun/Fornjot
synced 2025-05-11 21:38:31 +00:00
Track internal faces
This commit is contained in:
parent
a0d5716687
commit
fdd0338da5
@ -47,7 +47,7 @@ impl Sketch {
|
|||||||
},
|
},
|
||||||
);
|
);
|
||||||
|
|
||||||
Face::new(surface, half_edges)
|
Face::new(surface, half_edges, false)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -57,6 +57,7 @@ impl ConnectExt for Handle<Face> {
|
|||||||
is_internal: false,
|
is_internal: false,
|
||||||
})
|
})
|
||||||
}),
|
}),
|
||||||
|
q.is_internal,
|
||||||
);
|
);
|
||||||
Handle::new(face)
|
Handle::new(face)
|
||||||
})
|
})
|
||||||
|
@ -6,6 +6,10 @@ pub trait FlipExt {
|
|||||||
|
|
||||||
impl FlipExt for &Face {
|
impl FlipExt for &Face {
|
||||||
fn flip(self) -> Face {
|
fn flip(self) -> Face {
|
||||||
Face::new(self.surface.flip(), self.half_edges.clone())
|
Face::new(
|
||||||
|
self.surface.flip(),
|
||||||
|
self.half_edges.clone(),
|
||||||
|
self.is_internal,
|
||||||
|
)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -17,6 +17,7 @@ impl TranslateExt for Face {
|
|||||||
self.half_edges
|
self.half_edges
|
||||||
.iter()
|
.iter()
|
||||||
.map(|half_edge| Handle::new(half_edge.translate(offset))),
|
.map(|half_edge| Handle::new(half_edge.translate(offset))),
|
||||||
|
self.is_internal,
|
||||||
)
|
)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -15,16 +15,19 @@ use super::{half_edge::HalfEdge, vertex::Vertex};
|
|||||||
pub struct Face {
|
pub struct Face {
|
||||||
pub surface: Plane,
|
pub surface: Plane,
|
||||||
pub half_edges: Vec<Handle<HalfEdge>>,
|
pub half_edges: Vec<Handle<HalfEdge>>,
|
||||||
|
pub is_internal: bool,
|
||||||
}
|
}
|
||||||
|
|
||||||
impl Face {
|
impl Face {
|
||||||
pub fn new(
|
pub fn new(
|
||||||
surface: Plane,
|
surface: Plane,
|
||||||
half_edges: impl IntoIterator<Item = Handle<HalfEdge>>,
|
half_edges: impl IntoIterator<Item = Handle<HalfEdge>>,
|
||||||
|
is_internal: bool,
|
||||||
) -> Self {
|
) -> Self {
|
||||||
Self {
|
Self {
|
||||||
surface,
|
surface,
|
||||||
half_edges: half_edges.into_iter().collect(),
|
half_edges: half_edges.into_iter().collect(),
|
||||||
|
is_internal,
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user