frykauf / o3d

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

Documentation error quaternions.js #225

Open GoogleCodeExporter opened 9 years ago

GoogleCodeExporter commented 9 years ago
o3djs/quaternions.js header explains "Operations are done assuming quaternions 
are of the form: q[0] + q[1]i + q[2]j + q[3]k"

It seems reading the code that quaternions are of the following form:
q[0]i + q[1]j + q[2]k + q[3]

(ex of some function returning a quaternion:
o3djs.arcball.ArcBall.prototype.drag = function(newPoint) {
  ...
  return o3djs.math.cross(this.startVector_, this.endVector_).concat(
      o3djs.math.dot(this.startVector_, this.endVector_));
)

Original issue reported on code.google.com by yann.gil...@gmail.com on 23 Jun 2010 at 7:17