mirror of https://github.com/hannobraun/Fornjot
Remove redundant access to point curve coords
This commit is contained in:
parent
e1edb64c6f
commit
d4faf2973d
|
@ -24,7 +24,7 @@ impl Swept {
|
||||||
|
|
||||||
/// Convert a point in model coordinates to surface coordinates
|
/// Convert a point in model coordinates to surface coordinates
|
||||||
pub fn point_model_to_surface(&self, point: &Point<3>) -> Point<2> {
|
pub fn point_model_to_surface(&self, point: &Point<3>) -> Point<2> {
|
||||||
let u = self.curve.point_model_to_curve(point).t();
|
let u = self.curve.point_model_to_curve(point).t;
|
||||||
let v = (point - self.curve.origin()).dot(&self.path.normalize())
|
let v = (point - self.curve.origin()).dot(&self.path.normalize())
|
||||||
/ self.path.magnitude();
|
/ self.path.magnitude();
|
||||||
|
|
||||||
|
|
|
@ -53,13 +53,6 @@ impl<const D: usize> Point<D> {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
impl Point<1> {
|
|
||||||
/// Access the curve point's t coordinate
|
|
||||||
pub fn t(&self) -> Scalar {
|
|
||||||
self.coords.t
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
impl ops::Deref for Point<1> {
|
impl ops::Deref for Point<1> {
|
||||||
type Target = T;
|
type Target = T;
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue