diff --git a/crates/fj-kernel/src/algorithms/approx/cycle.rs b/crates/fj-kernel/src/algorithms/approx/cycle.rs index 51b364830..5b8b54da0 100644 --- a/crates/fj-kernel/src/algorithms/approx/cycle.rs +++ b/crates/fj-kernel/src/algorithms/approx/cycle.rs @@ -7,13 +7,13 @@ use fj_math::Segment; use crate::objects::{Cycle, Surface}; use super::{ - edge::{CurveCache, HalfEdgeApprox}, + edge::{EdgeCache, HalfEdgeApprox}, Approx, ApproxPoint, Tolerance, }; impl Approx for (&Cycle, &Surface) { type Approximation = CycleApprox; - type Cache = CurveCache; + type Cache = EdgeCache; fn approx_with_cache( self, diff --git a/crates/fj-kernel/src/algorithms/approx/edge.rs b/crates/fj-kernel/src/algorithms/approx/edge.rs index 84ead283e..cebf72bfb 100644 --- a/crates/fj-kernel/src/algorithms/approx/edge.rs +++ b/crates/fj-kernel/src/algorithms/approx/edge.rs @@ -17,7 +17,7 @@ use super::{path::RangeOnPath, Approx, ApproxPoint, Tolerance}; impl Approx for (&Handle, &Surface) { type Approximation = HalfEdgeApprox; - type Cache = CurveCache; + type Cache = EdgeCache; fn approx_with_cache( self, @@ -176,11 +176,11 @@ fn approx_edge( /// A cache for results of an approximation #[derive(Default)] -pub struct CurveCache { +pub struct EdgeCache { inner: BTreeMap<(ObjectId, RangeOnPath), GlobalEdgeApprox>, } -impl CurveCache { +impl EdgeCache { /// Create an empty cache pub fn new() -> Self { Self::default() diff --git a/crates/fj-kernel/src/algorithms/approx/face.rs b/crates/fj-kernel/src/algorithms/approx/face.rs index b81ff580b..d9baff01c 100644 --- a/crates/fj-kernel/src/algorithms/approx/face.rs +++ b/crates/fj-kernel/src/algorithms/approx/face.rs @@ -12,12 +12,12 @@ use crate::{ }; use super::{ - cycle::CycleApprox, edge::CurveCache, Approx, ApproxPoint, Tolerance, + cycle::CycleApprox, edge::EdgeCache, Approx, ApproxPoint, Tolerance, }; impl Approx for &FaceSet { type Approximation = BTreeSet; - type Cache = CurveCache; + type Cache = EdgeCache; fn approx_with_cache( self, @@ -65,7 +65,7 @@ impl Approx for &FaceSet { impl Approx for &Face { type Approximation = FaceApprox; - type Cache = CurveCache; + type Cache = EdgeCache; fn approx_with_cache( self, diff --git a/crates/fj-kernel/src/algorithms/approx/shell.rs b/crates/fj-kernel/src/algorithms/approx/shell.rs index 942d13a0f..0b9e3601d 100644 --- a/crates/fj-kernel/src/algorithms/approx/shell.rs +++ b/crates/fj-kernel/src/algorithms/approx/shell.rs @@ -4,11 +4,11 @@ use std::collections::BTreeSet; use crate::objects::Shell; -use super::{edge::CurveCache, face::FaceApprox, Approx, Tolerance}; +use super::{edge::EdgeCache, face::FaceApprox, Approx, Tolerance}; impl Approx for &Shell { type Approximation = BTreeSet; - type Cache = CurveCache; + type Cache = EdgeCache; fn approx_with_cache( self, diff --git a/crates/fj-kernel/src/algorithms/approx/sketch.rs b/crates/fj-kernel/src/algorithms/approx/sketch.rs index 0510cc167..873257a01 100644 --- a/crates/fj-kernel/src/algorithms/approx/sketch.rs +++ b/crates/fj-kernel/src/algorithms/approx/sketch.rs @@ -4,11 +4,11 @@ use std::collections::BTreeSet; use crate::objects::Sketch; -use super::{edge::CurveCache, face::FaceApprox, Approx, Tolerance}; +use super::{edge::EdgeCache, face::FaceApprox, Approx, Tolerance}; impl Approx for &Sketch { type Approximation = BTreeSet; - type Cache = CurveCache; + type Cache = EdgeCache; fn approx_with_cache( self, diff --git a/crates/fj-kernel/src/algorithms/approx/solid.rs b/crates/fj-kernel/src/algorithms/approx/solid.rs index 8995057c7..4aff45ecb 100644 --- a/crates/fj-kernel/src/algorithms/approx/solid.rs +++ b/crates/fj-kernel/src/algorithms/approx/solid.rs @@ -4,11 +4,11 @@ use std::collections::BTreeSet; use crate::objects::Solid; -use super::{edge::CurveCache, face::FaceApprox, Approx, Tolerance}; +use super::{edge::EdgeCache, face::FaceApprox, Approx, Tolerance}; impl Approx for &Solid { type Approximation = BTreeSet; - type Cache = CurveCache; + type Cache = EdgeCache; fn approx_with_cache( self,