Modeling, Bnd_Box - CornerMax incorrect realisation #664
Merged
dpasukhi merged 3 commits intoOpen-Cascade-SAS:IRfrom Aug 8, 2025
Merged
Modeling, Bnd_Box - CornerMax incorrect realisation #664dpasukhi merged 3 commits intoOpen-Cascade-SAS:IRfrom
dpasukhi merged 3 commits intoOpen-Cascade-SAS:IRfrom
Conversation
Fixed CornerMax with getting valid values from Bnd_Box. Before we are extracting Min. Added extended GTest tests.
There was a problem hiding this comment.
Pull Request Overview
This PR fixes a bug in the Bnd_Box::CornerMax() method where incorrect conditions were being checked for the Y and Z axes, causing the method to return min corner values instead of max corner values. The fix corrects the openness checks to use IsOpenYmax() and IsOpenZmax() instead of IsOpenYmin() and IsOpenZmin().
Key changes:
- Fixed the logical error in
CornerMax()method by correcting the openness condition checks - Added comprehensive GTest suite for
Bnd_Boxclass to prevent similar regressions - Minor code formatting improvements in the
DumpJson()method
Reviewed Changes
Copilot reviewed 3 out of 3 changed files in this pull request and generated 1 comment.
| File | Description |
|---|---|
| src/FoundationClasses/TKMath/Bnd/Bnd_Box.cxx | Fixed CornerMax method bug and improved DumpJson formatting |
| src/FoundationClasses/TKMath/GTests/Bnd_Box_Test.cxx | Added comprehensive test suite for Bnd_Box functionality |
| src/FoundationClasses/TKMath/GTests/FILES.cmake | Updated CMake to include new test file |
AtheneNoctuaPt
approved these changes
Aug 8, 2025
dpasukhi
added a commit
that referenced
this pull request
Sep 6, 2025
- Fixed the logical error in `CornerMax()` method by correcting the openness condition checks - Added comprehensive GTest suite for `Bnd_Box` class to prevent similar regressions - Minor code formatting improvements in the `DumpJson()` method
dpasukhi
added a commit
that referenced
this pull request
Sep 6, 2025
- Fixed the logical error in `CornerMax()` method by correcting the openness condition checks - Added comprehensive GTest suite for `Bnd_Box` class to prevent similar regressions - Minor code formatting improvements in the `DumpJson()` method
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Fixed CornerMax with getting valid values from Bnd_Box. Before we are extracting Min.
Added extended GTest tests.