Bacon / BaconQrCode

QR Code Generator for PHP
BSD 2-Clause "Simplified" License
1.86k stars 212 forks source link

TransformationMatrix calculations wrong(?) #63

Closed fsmeier closed 5 years ago

fsmeier commented 5 years ago

Heyho, I am trying to prepare a PR to support gd again, at least for non gradient drawing as mvp, but i have a problem with the transformation-matrix:

$matrix = TransformationMatrix::scale(2);
var_dump($matrix->apply(1, 2));
die();

I got as result sth like (2, 2), but it should be (2, 4). I have the feeling the matrix-calculations are wrong. Sadly i lost a lot of knowledge of matrixes over the years so i dont know how to fix and make a PR by my own.

Does anyone has an idea?

fsmeier commented 5 years ago

So found out the problem(s) and provided a PR, would be nice if you could have a look and merge (and release?) @DASPRiD

DASPRiD commented 5 years ago

PR was merged, fixed.