mih
Member
|
How to smoothly move camera from A to B ?
As in the title, any ideas ?
I was trying that but It didn't work (A and B are vectors):
Code:
camera_at = LerpTime(A,B),Tm.d()*20);
but maybe I don't understand how the interpolation works or maybe I used the wrong interpolation, I don't know.
|
|
02-10-2010 04:58 PM |
|
Esenthel
Administrator
|
RE: How to smoothly move camera from A to B ?
please use this:
void AdjustValTime (Flt &v,Flt target, Flt step ); // adjust value by smooth time interpolation, "v=LerpTime(v,target,step);"
Flt step=0..1
AdjustValTime(cam.at.x,dest.x,step);
AdjustValTime(cam.at.y,dest.y,step);
AdjustValTime(cam.at.z,dest.z,step);
for the next release ill make a
AdjustValTime(Vec &, Vec&, Flt step);
function
|
|
02-10-2010 05:03 PM |
|
mih
Member
|
RE: How to smoothly move camera from A to B ?
Ok thanks
|
|
02-10-2010 05:14 PM |
|