http://bugs.winehq.org/show_bug.cgi?id=36504
--- Comment #1 from Sebastian Lackner sebastian@fds-team.de --- @Other readers: I have analyzed the differences between the old and the new set of equations, you can find some more details here on the mailing list: http://www.winehq.org/pipermail/wine-devel/2014-June/104518.html
Most likely fixing the equation for eM22 should be sufficient, no need to rewrite the whole function:
xf.eM22 = (rect[1].x*(plg[2].y - plg[0].y) - rect[2].x*(plg[1].y - plg[0].y) - rect[0].x*(plg[2].y - plg[1].y)) / det;
@Alexander: Can you confirm that this single change resolves the issue? If yes I would suggest you to send a new patch, which really only modifies this part. I don't think you'll need to write a test for this single-line change, where most likely everyone can agree, that it looks like a mistake in the old code. The main problem of your huge patch was just, that noone could really follow, what has changed exactly.
Regards, Sebastian