mirror of https://github.com/hannobraun/Fornjot
Remove unused `CycleBuilder` methods
This commit is contained in:
parent
fa02019d44
commit
b22f1068f3
|
@ -16,11 +16,6 @@ pub struct CycleBuilder {
|
||||||
}
|
}
|
||||||
|
|
||||||
impl CycleBuilder {
|
impl CycleBuilder {
|
||||||
/// Create an instance of `CycleBuilder`
|
|
||||||
pub fn new() -> Self {
|
|
||||||
Self::default()
|
|
||||||
}
|
|
||||||
|
|
||||||
/// Create a cycle whose half-edges are connected to the provided half-edges
|
/// Create a cycle whose half-edges are connected to the provided half-edges
|
||||||
///
|
///
|
||||||
/// The half-edges of the new circle will be coincident with the provided
|
/// The half-edges of the new circle will be coincident with the provided
|
||||||
|
@ -46,25 +41,6 @@ impl CycleBuilder {
|
||||||
Self { half_edges }
|
Self { half_edges }
|
||||||
}
|
}
|
||||||
|
|
||||||
/// Create a polygon
|
|
||||||
pub fn polygon<P, Ps>(points: Ps, services: &mut Services) -> Self
|
|
||||||
where
|
|
||||||
P: Into<Point<2>>,
|
|
||||||
Ps: IntoIterator<Item = P>,
|
|
||||||
Ps::IntoIter: Clone + ExactSizeIterator,
|
|
||||||
{
|
|
||||||
let half_edges = points
|
|
||||||
.into_iter()
|
|
||||||
.map(Into::into)
|
|
||||||
.circular_tuple_windows()
|
|
||||||
.map(|(start, end)| {
|
|
||||||
HalfEdge::line_segment([start, end], None, services)
|
|
||||||
})
|
|
||||||
.collect();
|
|
||||||
|
|
||||||
Self { half_edges }
|
|
||||||
}
|
|
||||||
|
|
||||||
/// Build the cycle
|
/// Build the cycle
|
||||||
pub fn build(self, services: &mut Services) -> Cycle {
|
pub fn build(self, services: &mut Services) -> Cycle {
|
||||||
let half_edges = self
|
let half_edges = self
|
||||||
|
|
Loading…
Reference in New Issue