I had success with the focal length. Xtranormal’s specification is some kind of inverse of the specification that Blender uses. By trial and error I got an equation that approximates the relationship well enough.
Blender focal length = 1054.6 time (Xtranormal fov) -1.0149
I find that I still need to adjust this when I do a new camera.
I finally figured out the co-ordinate system Xtranormal uses. I had the y-axis and z-axis switched. I thought that would fix the problem with the orientation parameters. It didn’t solve the problem. Xtranormal appears to use quaternions, but when I use those in Blender they point the camera in the wrong direction. Frustrating.
I really don’t think I will come up with some easy way to transform the orientation parameters. I did come up with an approach that seems to work, but is very time consuming.
- In Xtranormal I use the location markers to define the corners of a camera image.
- I save the STATE file and get the and used them to identify the corners of the camera frame.
- I unzip the STATE file and get the co-ordinates of the corners from the document.xml file.
- I use those co-ordinates to create a plane in Blender
- I adjust the camera orientation and focal length to match the plane I created.
It is only an approximation, but I think it should work well enough. I have done five cameras so far. There are 30 cameras altogether. I think some of them are duplicates, or close to duplicates, so I won’t need to do them all.