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

Harmonize camera animation systems #1972

Open
jailln opened this issue Dec 23, 2022 · 1 comment
Open

Harmonize camera animation systems #1972

jailln opened this issue Dec 23, 2022 · 1 comment

Comments

@jailln
Copy link
Contributor

jailln commented Dec 23, 2022

The GlobeControls have one camera animation system (Animation Player) and the CameraUtils have another one (Tweenjs used in the CameraRig class) and they are not synchronized. Therefore, triggering a move with CameraUtils.transformCameraToLookAtTarget while the camera is animated with the GlobeControls results in a buggy behaviour:

bug-cam-itowns

A bypass is to call view.controls.player.stop() before using the CameraUtils but it is a bit hacky 🙂

I think we should harmonize animation systems and use only one if possible or ensure that they are "synchronized" (i.e. one is stopped before the other starts).

@jailln jailln added this to the 2.xx.x milestone Dec 23, 2022
@valentinMachado
Copy link
Contributor

valentinMachado commented Apr 21, 2023

We could also consider that PlanarControl is handling its own camera animation using the MAIN_LOOP

I agree with you, using one animation system is the right way to proceed.
Tween seems fine to me: good api, possibility of easing and large communauty making it easy to use and well supported.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants