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
ArcRotateCamera: Modified zoomOn to use same logic as FramingBehavior #14387
Conversation
Please make sure to label your PR with "bug", "new feature" or "breaking change" label(s). |
Please make sure to label your PR with "bug", "new feature" or "breaking change" label(s). |
Snapshot stored with reference name: Test environment: To test a playground add it to the URL, for example: https://babylonsnapshots.z22.web.core.windows.net/refs/pull/14387/merge/index.html#WGZLGJ#4600 Links to test babylon tools with this snapshot: https://playground.babylonjs.com/?snapshot=refs/pull/14387/merge To test the snapshot in the playground with a playground ID add it after the snapshot query string: https://playground.babylonjs.com/?snapshot=refs/pull/14387/merge#BCU1XR#0 |
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.
If the frustrumSlope function is only use in this context, I would suggest to call it from within LowerRadius... instead of separately outside ?
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.
Just two comments, otherwise - looks good
A user on the forum found that the
zoomOn
function was found to be incorrectly determining radius for zooming on provided meshes. This PR contains a change that takes some of the logic used for theArcRotateCamera
framing behavior and uses that to determine how far to zoom.Forum Link: https://forum.babylonjs.com/t/arcrotate-camera-zoomon-not-working-as-expected/38130/1