Skip to content

Commit

Permalink
Add comments
Browse files Browse the repository at this point in the history
  • Loading branch information
hannobraun committed Nov 8, 2022
1 parent 1e8c8ee commit 39f7003
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 0 deletions.
5 changes: 5 additions & 0 deletions crates/fj-kernel/src/validate/cycle.rs
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,11 @@ impl Validate2 for Cycle {
_: &ValidationConfig,
) -> Result<(), Self::Error> {
CycleValidationError::check_half_edge_connections(self)?;

// We don't need to check that all half-edges are defined in the same
// surface. We already check that they are connected by identical
// surface vertices, so that would be redundant.

Ok(())
}
}
Expand Down
5 changes: 5 additions & 0 deletions crates/fj-kernel/src/validate/edge.rs
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,11 @@ impl Validate2 for HalfEdge {
HalfEdgeValidationError::check_global_curve_identity(self)?;
HalfEdgeValidationError::check_global_vertex_identity(self)?;
HalfEdgeValidationError::check_vertex_positions(self, config)?;

// We don't need to check anything about surfaces here. We already check
// curves, which makes sure the vertices are consistent with each other,
// and the validation of those vertices checks the surfaces.

Ok(())
}
}
Expand Down

0 comments on commit 39f7003

Please sign in to comment.