kerou / o3d

Automatically exported from code.google.com/p/o3d
0 stars 0 forks source link

o3djs.quaternions.rotationToQuaternion returns [NaN NaN,0,NaN] when applied to identity matrix #224

Open GoogleCodeExporter opened 9 years ago

GoogleCodeExporter commented 9 years ago
What steps will reproduce the problem?
1. feeding [[1,0,0,0],[0,1,0,0],[0,0,1,0],[0,0,0,1]] to rotationToQuaternion

What is the expected output? What do you see instead?
[0,0,0,1]
I see
[Nan,Nan,0,Nan]

What version of the product are you using? On what operating system?
svn head

Additional information:
the correct algorithm should look more like (attached)
The attached algorithm has not be carefully tested in a wide variety of 
situations, but it seems to do well on the small stuff tested so far

Original issue reported on code.google.com by danie...@gmail.com on 12 Jun 2010 at 5:54

Attachments: