Skip to content

Commit

Permalink
Remove fj::Sweep::color
Browse files Browse the repository at this point in the history
It's not necessary, as it's just an alias for a method that is almost as
easy to access. And it's confusing, as it implies that a sweep has its
own color that's potentially separate from the swept shape.
  • Loading branch information
hannobraun committed Mar 29, 2022
1 parent 45269c8 commit 13b201b
Show file tree
Hide file tree
Showing 2 changed files with 1 addition and 6 deletions.
2 changes: 1 addition & 1 deletion fj-operations/src/sweep.rs
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ impl ToShape for fj::Sweep {
self.shape().to_shape(tolerance, debug_info),
Vector::from([0., 0., self.length()]),
tolerance,
self.color(),
self.shape().color(),
)
}

Expand Down
5 changes: 0 additions & 5 deletions fj/src/shape_3d.rs
Original file line number Diff line number Diff line change
Expand Up @@ -113,11 +113,6 @@ impl Sweep {
pub fn length(&self) -> f64 {
self.length
}

/// Access the color of the shape being swept
pub fn color(&self) -> [u8; 4] {
self.shape().color()
}
}

impl From<Sweep> for Shape {
Expand Down

0 comments on commit 13b201b

Please sign in to comment.