Skip to content

Conversation

georginahalpern
Copy link
Contributor

@georginahalpern georginahalpern commented Sep 25, 2025

Until we have framerate-based movement system (feature coming in 9.0), exposing ability for users to override epsilon per-frame to customize clamping behavior.

This helps avoid inconsistent motion behavior on higher framerate devices, described in this forum post.

https://forum.babylonjs.com/t/camera-inertia-causes-inconsistent-motion/60633/11

@bjsplat
Copy link
Collaborator

bjsplat commented Sep 25, 2025

Please make sure to label your PR with "bug", "new feature" or "breaking change" label(s).
To prevent this PR from going to the changelog marked it with the "skip changelog" label.

@ReedSyllas
Copy link

Hi!

Does speed need to be included in the calculation at arcRotateCamera.ts:1066 and arcRotateCamera.ts:1069? I can see that this.speed isn't there, but I think it should've been?

From my personal testing it seems required. The bad behavior comes back without it.

@bjsplat
Copy link
Collaborator

bjsplat commented Sep 25, 2025

@bjsplat
Copy link
Collaborator

bjsplat commented Sep 25, 2025

@bjsplat
Copy link
Collaborator

bjsplat commented Sep 25, 2025

@bjsplat
Copy link
Collaborator

bjsplat commented Sep 25, 2025

@bjsplat
Copy link
Collaborator

bjsplat commented Sep 25, 2025

@sebavan sebavan marked this pull request as draft September 25, 2025 21:30
@georginahalpern georginahalpern changed the title Calculate inertia using localspeed rather than const speed in target/arcrotate cameras Scale inertialLimit based on time since last frame to get consistent behavior across different FPS Sep 29, 2025
@bjsplat
Copy link
Collaborator

bjsplat commented Sep 29, 2025

Please make sure to label your PR with "bug", "new feature" or "breaking change" label(s).
To prevent this PR from going to the changelog marked it with the "skip changelog" label.

@bjsplat
Copy link
Collaborator

bjsplat commented Sep 29, 2025

@bjsplat
Copy link
Collaborator

bjsplat commented Sep 29, 2025

@bjsplat
Copy link
Collaborator

bjsplat commented Sep 29, 2025

@bjsplat
Copy link
Collaborator

bjsplat commented Sep 29, 2025

@bjsplat
Copy link
Collaborator

bjsplat commented Sep 29, 2025

@georginahalpern georginahalpern changed the title Scale inertialLimit based on time since last frame to get consistent behavior across different FPS Offer override of _panningEpsilon and _rotationEpsilon which are used to calculate per-frame inertial limit Sep 30, 2025
@georginahalpern georginahalpern changed the title Offer override of _panningEpsilon and _rotationEpsilon which are used to calculate per-frame inertial limit Internally expose _panningEpsilon and _rotationEpsilon which are used to calculate per-frame inertial limit Sep 30, 2025
@georginahalpern georginahalpern changed the title Internally expose _panningEpsilon and _rotationEpsilon which are used to calculate per-frame inertial limit Internally expose _panningEpsilon and _rotationEpsilon which are used to calculate inertial limit Sep 30, 2025
@bjsplat
Copy link
Collaborator

bjsplat commented Sep 30, 2025

@bjsplat
Copy link
Collaborator

bjsplat commented Sep 30, 2025

@bjsplat
Copy link
Collaborator

bjsplat commented Sep 30, 2025

@bjsplat
Copy link
Collaborator

bjsplat commented Sep 30, 2025

@georginahalpern georginahalpern marked this pull request as ready for review September 30, 2025 18:52
@georginahalpern georginahalpern merged commit 1808908 into BabylonJS:master Sep 30, 2025
20 checks passed
@georginahalpern georginahalpern deleted the cameraFix branch September 30, 2025 18:52
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants