1
0
mirror of https://git.dev.opencascade.org/repos/occt.git synced 2025-08-09 13:22:24 +03:00

0022736: Incorrect Transformation

This commit is contained in:
SZV and JGV
2011-10-11 13:41:48 +00:00
committed by bugmaster
parent 68bc5ed764
commit 4714a7a650
2 changed files with 70 additions and 2 deletions

View File

@@ -196,8 +196,12 @@ void gp_Trsf2d::Multiply(const gp_Trsf2d& T)
}
else if (shape == gp_Ax1Mirror && T.shape == gp_Ax1Mirror) {
shape = gp_Rotation;
loc.Add (T.loc.Multiplied (matrix));
matrix.Multiply(T.matrix);
gp_XY Tloc (T.loc);
Tloc.Multiply (matrix);
Tloc.Multiply (scale);
scale = scale * T.scale;
loc.Add (Tloc);
matrix.Multiply (T.matrix);
}
else if ((shape == gp_CompoundTrsf || shape == gp_Rotation ||
shape == gp_Ax1Mirror) && T.shape == gp_Translation) {
@@ -409,6 +413,8 @@ void gp_Trsf2d::PreMultiply (const gp_Trsf2d& T)
else if (shape == gp_Ax1Mirror && T.shape == gp_Ax1Mirror) {
shape = gp_Rotation;
loc.Multiply (T.matrix);
loc.Multiply(T.scale);
scale = scale * T.scale;
loc.Add (T.loc);
matrix.PreMultiply(T.matrix);
}