This is more a question of curiosity why MatrixTransform the way it is, rather than a real problem.
MSDN gives the affine transformation matrix of MatrixTransform like this:
m11 m12 0
A := m21 m22 0
offX offY开发者_如何学运维 1
http://msdn.microsoft.com/en-us/library/system.windows.media.matrixtransform(v=VS.100).aspx
To transform a point, you use it this way: x' = xTA
. This is different from what I would expect - x' = Ax
, which uses this matrix:
m11 m12 offX
A := m21 m22 offY
0 0 1
I realize that this makes no difference for the implementation of MatrixTransform, but I wonder if am missing some insight here. Does anyone know why the transformation matrix is specified the way it is?
It's just a convention to have the matrix row-major instead of column major. Most computer graphics systems follow this convention.
精彩评论