Tag Info

New answers tagged


mklingen's comment answered my question. I was correct in my initial guess.


The transform method of Vector class is wrong. If you want to perform a transformation of the vector that is equivalent to multiplying a vector by a transform matrix, you should modify your code as follows: void Vector2::transform(double a, double b, double c, double d) { double newX = a*x + b*y; y = c*x + d*y; x = newX; }

Top 50 recent answers are included