Skip to content
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

csg-tree: fix subtraction #1103

Merged
merged 2 commits into from
Dec 7, 2024
Merged

csg-tree: fix subtraction #1103

merged 2 commits into from
Dec 7, 2024

Conversation

pca006132
Copy link
Collaborator

@pca006132 pca006132 commented Dec 6, 2024

Closes #1102.

Copy link

codecov bot commented Dec 6, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 91.87%. Comparing base (aacf37a) to head (e9a9e81).
Report is 1 commits behind head on master.

Additional details and impacted files
@@           Coverage Diff           @@
##           master    #1103   +/-   ##
=======================================
  Coverage   91.87%   91.87%           
=======================================
  Files          30       30           
  Lines        5883     5885    +2     
=======================================
+ Hits         5405     5407    +2     
  Misses        478      478           

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

Copy link
Owner

@elalish elalish left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks!

src/csg_tree.cpp Outdated
@@ -494,7 +498,7 @@ std::shared_ptr<CsgLeafNode> CsgOpNode::ToLeafNode() const {
// Before performing boolean operations, we should make sure that all children
// are `CsgLeafNodes`, i.e. are actual meshes that can be operated on. Hence,
// we do it in two steps:
// 1. Populate `children` (`left_children` and `right_children`, see below)
// 1. Populate `children` (`positive_children` and `positive_children`)
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

and negative?

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

nice catch

@pca006132 pca006132 merged commit ec0bbca into master Dec 7, 2024
25 checks passed
@pca006132 pca006132 deleted the csg-tree branch December 7, 2024 07:39
@elalish elalish mentioned this pull request Dec 26, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

CSG tree simplify subtractions
2 participants