-
Notifications
You must be signed in to change notification settings - Fork 37
Refactor BroadPhase to Build from Vertex Boxes Directly #187
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
- Moved the inclusion of the CCD library to a new position in CMakeLists.txt for better organization. - Updated CPM version from 0.40.2 to 0.42.0 in CPM.cmake. - Modified ccd_query_io.cmake to use the new CPMAddPackage syntax with options. - Updated finite_diff.cmake to use the latest version of the finite-diff package (1.0.3). - Adjusted libigl.cmake to use the new CPMAddPackage syntax with options. - Updated scalable_ccd.cmake to use the new CPMAddPackage syntax with options. - Refactored BroadPhase class methods in broad_phase.cpp and broad_phase.hpp to streamline the build process. - Enhanced HashGrid class methods in hash_grid.cpp and hash_grid.hpp for better clarity and efficiency. - Improved SpatialHash class methods in spatial_hash.cpp and spatial_hash.hpp to utilize precomputed AABBs. - Added new methods to SweepAndPrune and SweepAndTiniestQueue classes for building from precomputed AABBs. - Introduced a new function to suggest a good voxel size based on AABBs in voxel_size_heuristic.cpp and voxel_size_heuristic.hpp. - Optimized edge_edge_mollifier.cpp with FMA operator in gradient calculations. - Updated eigen_ext.tpp to improve error handling during matrix projections. - Added a static method to create an empty interval in interval.hpp.
Codecov Report❌ Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## main #187 +/- ##
==========================================
- Coverage 96.18% 96.02% -0.16%
==========================================
Files 105 105
Lines 8064 8100 +36
==========================================
+ Hits 7756 7778 +22
- Misses 308 322 +14
Flags with carried forward coverage won't be shown. Click here to find out more. ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pull Request Overview
This PR refactors the BroadPhase class hierarchy to build from pre-computed vertex AABBs directly rather than from vertex positions. The changes streamline the build process by eliminating redundant vertex box computation across different broad phase implementations.
Key changes:
- Added a new
build()
method overload that accepts precomputedstd::vector<AABB>
vertex boxes - Refactored all broad phase implementations to use vertex boxes as the primary data source
- Updated CMake configuration files to use newer versions and improved syntax
Reviewed Changes
Copilot reviewed 26 out of 26 changed files in this pull request and generated 2 comments.
Show a summary per file
File | Description |
---|---|
tests/src/tests/broad_phase/test_broad_phase.cpp | Added test for new vertex box-based build functionality |
src/ipc/utils/interval.hpp | Added empty interval factory method |
src/ipc/utils/eigen_ext.tpp | Improved error handling in matrix projection functions |
src/ipc/distance/edge_edge_mollifier.cpp | Optimized gradient calculation with FMA operation |
src/ipc/ccd/narrow_phase_ccd.hpp | Added comprehensive documentation for CCD methods |
src/ipc/candidates/candidates.hpp | Added documentation for public methods |
src/ipc/broad_phase/* | Refactored all broad phase classes to build from vertex boxes |
cmake/recipes/* | Updated to newer package versions and improved CPMAddPackage syntax |
CMakeLists.txt | Reorganized CCD library inclusion for better organization |
Tip: Customize your code reviews with copilot-instructions.md. Create the file or learn how to get started.
Description
Type of change