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
Fix frustum intersectsSprite bug, fix #24822 #24828
base: dev
Are you sure you want to change the base?
Conversation
@06wj Thank you for this PR. But remember, this does not have to be a pixel-perfect calculation. It is OK for the bounding sphere to be conservative (i.e., oversized). Perhaps something less-computational may be preferable... |
@06wj For example, the sphere center can remain at zero. Maybe it is sufficient to simply increase (double?) the radius to account for the worst-case center offset. |
this.center = new Vector2( 0.5, 0.5 ); // should be between 0 and 1 See #12931. Do we need to support centers outside of [ 0, 1 ]? |
This restriction is not found in the documentation or in the code |
Even if centers outside [ 0, 1 ] are supported, I think the PR only requires changing the sphere radius. I think a sufficient radius can be computed given the center coordinates. |
2022-10-22.4.01.55.movAdded visualization of bounding spheres. |
Fixed #24822