All of those conditions are optimized equivalents to getting the determinant.

invert() is a destructive call, but since getTransform is documented to return a copy, that is fine - but getDeterminant() will involve less math to check the condition...

                        ...jim

On 9/27/16 6:33 AM, Clemens Eisserer wrote:
Hi Sergey

I guess you can use "getDeterminant()==0" to determine if this transform has
no inverse?

Initially I had the same idea, but looking at the implementation of
invert(), I found several different conditions leading to an
NoninvertibleTransformException. So I decided to keep the call to
invert(), as the code-path shouldn't be performance critical anyway.

Best regards, Clemens

Reply via email to