[SOLVED] startPoint for camera.lookAt?

I want to switch from instant lookAt for camera to a kind of smooth transition…
LookAt() works fine, but it`s so rapid…
To lerp I need a starting Point… :frowning:
oldViewPos = this.camera.lookAt(What??);

then lerp to new view

I know there is a lot of stuff out there to solve…
But my coding is so bad it doesnt’t doesent allow, pacages, or scripts a.s.o.

normaly I use many cameras in my projects, and I allways now where they are and where to look;
I’m alittle bit surprise, I can’t handle this… but there is to much random i my game…

happy lerping
:cucumber:

what is => What

i tried to research on google and forum, but after some amount od white wine :drozy:
I get lazy…
and I cant jugest verry good on what I read…

double sorry
:cucumber:

Hi @Gurki,

Check this forum post, it contains some ideas on how to approach that together with code snippets:

2 Likes

issue is solved, didn’t remember that a Vec3 is a pointer :crazy_face:
so as I lerped I’ve changed my target vector with every call…

current = target.clone().lerp(a,b, step);
lookAt(current)

did the job…

thanx :cucumber:

1 Like