Apply transform to content bounding volume #322
Merged
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.
Fixes #321
When there was a tile with a
transform
, andcontent
that had aboundingVolume
, then thetransform
was only applied to the tile bounding volume, but not to the content bounding volume. This was a leftover from the original/"legacy" bounding volume checks, and caused aBOUNDING_VOLUMES_INCONSISTENT
to be reported erroneously.Fortunately, it was an easy fix.
I did add a test for the case of bounding
box
objects. But in general, some parts of the "legacy" bounding volume containment checks could receive some additional coverage. It would be nice to cover the whole cartesian product ofbox
andbox
box
andsphere
box
andregion
sphere
andbox
sphere
andsphere
sphere
andregion
region
andbox
region
andsphere
region
andregion
both with and without
transform
, and a positive and a negative case, respectively. But I'd have to allocate more time to actually create these 36 tilesets...