updateCamOnObjectInfoChange

Modifies the camera position on change of the mesh info values (that is mainly the object's position and bounding box).

Details

The function calculates the change between the former and the new center of the 3d model's bounding box center. Then it applies this change to the camera, what means that the camera shifts accordingly to the object. This is important, when the object moves or gets bigger/smaller. (Note that this function takes into account that the camera origin is not necessary at the 3d model center, what is important when camera 'strafing' movement is possible.)

In a second step it recalculates the distance between the camera origin an focus point. Here the idea is to keep the camera aperture value while getting the image filled by the 3d model.