Instead of using the built-in camera fitting function, which wants to rotate the camera, it now calculates the local bounding box of the object for each camera angle.