MultiplyMatrixVector multiplies the matrix m with the point and returns the result.
(m *Matrix)
| 539 | |
| 540 | // MultiplyMatrixVector multiplies the matrix m with the point and returns the result. |
| 541 | func (p *Point) MultiplyMatrixVector(m *Matrix) *Point { |
| 542 | x := m.Val[m00]*p.X + m.Val[m01]*p.Y + m.Val[m02] |
| 543 | y := m.Val[m10]*p.X + m.Val[m11]*p.Y + m.Val[m12] |
| 544 | p.X, p.Y = x, y |
| 545 | return p |
| 546 | } |
no outgoing calls