Skip to content

Commit

Permalink
Fix dlib.math.transformation.scaling
Browse files Browse the repository at this point in the history
  • Loading branch information
gecko0307 committed May 13, 2020
1 parent dcdc0d7 commit 92746b9
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion dlib/math/transformation.d
Original file line number Diff line number Diff line change
Expand Up @@ -136,7 +136,10 @@ do
Vector!(T,3) scaling(T) (Matrix!(T,4) m)
do
{
return Vector!(T,3)(m.a11, m.a22, m.a33);
T sx = Vector!(T,3)(m.a11, m.a12, m.a13).length;
T sy = Vector!(T,3)(m.a21, m.a22, m.a23).length;
T sz = Vector!(T,3)(m.a31, m.a32, m.a33).length;
return Vector!(T,3)(sx, sy, sz);
}

/*
Expand Down

0 comments on commit 92746b9

Please sign in to comment.