corrected a bug in ApplySimilarity (the translation was not zeroed when
transforming the rotational part)
This commit is contained in:
parent
bf01793bd8
commit
f20ecb9db7
|
@ -509,9 +509,10 @@ void Shot<S, RotationType>::ApplySimilarity( Matrix44<S> M)
|
|||
|
||||
vcg::Matrix44<S> M2 = M;
|
||||
|
||||
M2 = M2 * scalefactor;
|
||||
M2[3][3] = 1.0; //unnecessary, it will multiply a pure rotation
|
||||
|
||||
M2 = M2 * scalefactor; // remove the rotation
|
||||
M2[3][3] = 1.0;
|
||||
M2[0][3] = M2[1][3] = M2[2][3] = 0; // remove the translation
|
||||
|
||||
rotM = rotM * M2.transpose();
|
||||
Extrinsics.SetRot(rotM);
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue