FBX Importer Bugs

So I’ve been trying to track down what is going on with random objects, like the spotlight receiving a totally different location and rotation than what it’s set as in Blender. In fact, if you set it at exactly the same location, and rotation as a camera, it will inexplicitly get off setted and have a seemingly random rotation applied.

I have talked with Blender support and the FBX file is fine, it imports back to Blender fine, and other DCC. The FBX SDK also reads the file correctly. So Three.js is randomly modulating the Spotlights rotation and location. I can’t figure out where this is happening, though.

For example the Spotlight in the node tree has a postion and rotation of the following:

		{"id": "Light.001", 
			"rotation": [-0.115075,  0.881120,  0.277816,  0.364972], 
			"scale": [ 100.000000,  99.999992,  99.999992], 
			"translation": [-250.000000,  500.000000,  250.000000]}

Within Three.JS this now becomes:

position: Object { x: 311.2372438157516, y: 250.00001785004994, z: -311.2372412076495 }
x: 311.2372438157516
y: 250.00001785004994
z: -311.2372412076495
rotation: Object { _x: 1.9583931751202461, _y: 0.36136719684331386, _z: -2.4278683133620076, … }
_order: "XYZ"
_x: 1.9583931751202461
_y: 0.36136719684331386
_z: -2.4278683133620076

Which is wrong.

camera-spotlight-light.blend (782.6 KB)
camera-spotlight-light.fbx (26.0 KB)