Remove Curve's TransformObject implementation

This commit is contained in:
Hanno Braun 2023-02-24 16:00:25 +01:00
parent e697c3ff6a
commit 2322ab9ddc
3 changed files with 3 additions and 26 deletions

View File

@ -1,23 +0,0 @@
use fj_math::Transform;
use crate::{
objects::{Curve, Objects},
services::Service,
};
use super::{TransformCache, TransformObject};
impl TransformObject for Curve {
fn transform_with_cache(
self,
_: &Transform,
_: &mut Service<Objects>,
_: &mut TransformCache,
) -> Self {
// Don't need to transform path, as that's defined in surface
// coordinates, and thus transforming `surface` takes care of it.
let path = self.path();
Self::new(path)
}
}

View File

@ -15,8 +15,9 @@ impl TransformObject for HalfEdge {
objects: &mut Service<Objects>,
cache: &mut TransformCache,
) -> Self {
let curve =
self.curve().transform_with_cache(transform, objects, cache);
// Don't need to transform curve, as that's defined in surface
// coordinates.
let curve = self.curve();
let boundary = self.boundary().zip_ext(self.surface_vertices()).map(
|(point, surface_vertex)| {
let surface_vertex = surface_vertex

View File

@ -1,6 +1,5 @@
//! API for transforming objects
mod curve;
mod cycle;
mod edge;
mod face;