Don't rely on `Shape::faces` in `ShapeProcessor`

This commit is contained in:
Hanno Braun 2022-06-28 15:22:16 +02:00
parent c14212c89d
commit f6cec1f5f6
1 changed files with 2 additions and 2 deletions

View File

@ -3,6 +3,7 @@
use fj_interop::{debug::DebugInfo, mesh::Mesh}; use fj_interop::{debug::DebugInfo, mesh::Mesh};
use fj_kernel::{ use fj_kernel::{
algorithms::{triangulate, InvalidTolerance, Tolerance}, algorithms::{triangulate, InvalidTolerance, Tolerance},
iter::ObjectIters,
validation::{ValidationConfig, ValidationError}, validation::{ValidationConfig, ValidationError},
}; };
use fj_math::{Aabb, Point, Scalar}; use fj_math::{Aabb, Point, Scalar};
@ -42,8 +43,7 @@ impl ShapeProcessor {
let mut debug_info = DebugInfo::new(); let mut debug_info = DebugInfo::new();
let shape = shape let shape = shape
.to_shape(&config, tolerance, &mut debug_info)? .to_shape(&config, tolerance, &mut debug_info)?
.faces() .face_iter()
.map(|handle| handle.get())
.collect(); .collect();
let mesh = triangulate(shape, tolerance, &mut debug_info); let mesh = triangulate(shape, tolerance, &mut debug_info);