Skip to content

Order of multiplication wrong in affine transformation tutorial

Submitted by kingpotter

Assigned to Nobody

Link to original bugzilla bug (#443)
Version: 3.0

Description

on the documentation page:

http://eigen.tuxfamily.org/api/TutorialGeometry.html

The subsection that talks about transformation creation

Procedural API : t.translate(Vector_(tx,ty,..));
Equivalent natural API: t *= Translation_(tx,ty,..);

This is correct
But:

I tested that t = Translation_(tx,ty,..); means t = tTranslation_(tx,ty,..);

NOT: t = Translation_(tx,ty,..) * t;

When applying a set of affine transformations, say:
t = t.setIdentity();
t = t.translate(a);
t = t.rotate(b);
t = t.scale(c);

Eventually, t is: Translate(a)*Rotate(b)*Scale(c);

The order of multiplication every time happens at the right side. This is called applying transformation to coordinate system instead of applying to points in graphics.

Edited by Eigen Bugzilla