[2/2] gdiplus: fix a warning in GdipMultiplyTextureTransform

Henri Verbeet hverbeet at gmail.com
Wed Dec 3 10:15:51 CST 2008

2008/12/3 Nikolay Sivov <bunglehead at gmail.com>:
> -    return GdipMultiplyMatrix(brush->transform, matrix, order);
> +    return GdipMultiplyMatrix(brush->transform, (GpMatrix*)matrix, order);

I don't think casting const away makes it much better. Considering
what the function does, and the fact that the matrix *is* const in the
prototype for Matrix::Multiply(), I'd say it would be better to just
change the prototype for GdipMultiplyMatrix. MS doesn't seem to care a
whole lot about their plain C interfaces these days.

Slightly OT, the code in matrix_multiply() isn't quite the most
efficient way to multiply two 2x3 matrices, although if you're lucky
the compiler will unroll the loop for you and fold the constants.

More information about the wine-devel mailing list