I am trying to interpolate the camera size with this code:
// t counts between 0 and 1
cam.orthographicSize = Mathf.SmoothStep(cam.orthogaphicSize, CAMERA_DEFAULT_ZOOM * ZoomFactor, t);
The issue is that this does not produce a smooth result.
I think that is because I update orthographicSize and use it as the starting point for each iteration.
What is the proper way of interpolating with a moving start value ?
One option i thought of was to keep track of the orthographicSize at the moment of starting the interpolation. I am not sure that is the best approach.
↧