Camera movement and switching problems

Hello Needle,

I use two camera in my scene, one perspective and another orthographic.
I generated a component to manage the angles, but I have a big problem : when I change the angle of view of my “main camera” which is the perspective one, there is not problem.
But when I tried to use the exact same behaviour with my orthographic camera, it vibrates like the position is

I change my camera by using :

document.getElementById(this.buttonId)?.addEventListener('click', (el) => {
                let e = el

                if(this.originalCameraComponent && this.orthographicCameraComponent) {
                    if(this.isSecondCamera) {
                        this.isSecondCamera = false
                    } else {
                        // @ts-ignore
                        this.isSecondCamera = true

Here the component used for change angleviews :

After verification, I change the position of my camera only in my angle view script. Nowhere else.
Do you have any idea of the problem ?

Original Post on Discord

by user 224464722878005248

Hey :wave: vibrating ortographic camera doesn’t sound correct at all. Often vibration would be caused by not having enough Z precision → resulting in z-fighting.

But your near and far clipping planes are more then generous.

Just as a quick test that it is caused by the orto cam itself. Could you change the orto cam to perspective and set the fov to something low like 1-5 FOV (you’ll have to push the camera a bit back and potentially edit the near-far if z-fighting occures.

Also by any chance, could you make a video of the “vibration”?

It was a problem with the orthographic camera you were right.
I changed also my function to update the angle view, thanks to you

by user 224464722878005248

like it :

by user 224464722878005248

:+1: glad to help :cactus: