Hey All,
I’m having to hand write an importer, which is coming along pretty well, but, am having trouble understanding how some of the parameters work together in the <node> blocks.
So, basically, I imported an FBX file for reference that loads in correctly…
FBX values:
The “Light” is at:
Translation: 0, 0.3048, 0.1969008
Rotation: 0, 0, 0
The “spotLight” is at:
Translation: -0.336533, 1.624422, 0.7187547
Rotation (Euler): 60.59999, 344.8, 0
So, how does 0, 15.2, -29.4 in the spotLight’s rotation ultimately translate to 60.6, 344.8, 0. I’m 99.9% sure that it has something to do with the “rotatePivot”, “rotatePivotInverse”, “scalePivot”, and “scalePivotInverse”. I’m just not sure how these work, and I don’t see any documentation for them in the 1.4.1 spec PDF.
The unitScale parameter is: 0.3048
<visual_scene id="VisualSceneNode" name="Scene01">
<node id="Lights" name="Lights" type="NODE">
<translate sid="rotatePivot">0 1 0.646</translate>
<rotate sid="rotateZ">0 0 1 0</rotate>
<rotate sid="rotateY">0 1 0 0</rotate>
<rotate sid="rotateX">1 0 0 0</rotate>
<translate sid="rotatePivotInverse">0 -1 -0.646</translate>
<translate sid="scalePivot">0 1 0.646</translate>
<translate sid="scalePivotInverse">0 -1 -0.646</translate>
<node id="spotLight1" name="spotLight1" type="NODE">
<translate sid="translate">1.10411 6.32947 3.00412</translate>
<rotate sid="rotateZ">0 0 1 0</rotate>
<rotate sid="rotateY">0 1 0 15.2</rotate>
<rotate sid="rotateX">1 0 0 -29.4</rotate>
<scale sid="scale">9.19261 9.19261 9.19261</scale>
<instance_light url="#spotLightShape1-lib"/>
</node>
Thanks a lot for any help,
Nathan