@@ -301,7 +301,7 @@ public static Size GetTransformedSize(Matrix4x4 matrix, Size size)
301
301
{
302
302
Guard . IsTrue ( size . Width > 0 && size . Height > 0 , nameof ( size ) , "Source size dimensions cannot be 0!" ) ;
303
303
304
- if ( matrix . Equals ( default ) || matrix . Equals ( Matrix4x4 . Identity ) )
304
+ if ( matrix . IsIdentity || matrix . Equals ( default ) )
305
305
{
306
306
return size ;
307
307
}
@@ -376,7 +376,7 @@ private static Size GetTransformedSize(Matrix3x2 matrix, Size size, TransformSpa
376
376
{
377
377
Guard . IsTrue ( size . Width > 0 && size . Height > 0 , nameof ( size ) , "Source size dimensions cannot be 0!" ) ;
378
378
379
- if ( matrix . Equals ( default ) || matrix . Equals ( Matrix3x2 . Identity ) )
379
+ if ( matrix . IsIdentity || matrix . Equals ( default ) )
380
380
{
381
381
return size ;
382
382
}
@@ -412,7 +412,7 @@ private static Size GetTransformedSize(Matrix3x2 matrix, Size size, TransformSpa
412
412
/// </returns>
413
413
private static bool TryGetTransformedRectangle ( RectangleF rectangle , Matrix3x2 matrix , out Rectangle bounds )
414
414
{
415
- if ( rectangle . Equals ( default ) || Matrix3x2 . Identity . Equals ( matrix ) )
415
+ if ( matrix . IsIdentity || rectangle . Equals ( default ) )
416
416
{
417
417
bounds = default ;
418
418
return false ;
@@ -439,7 +439,7 @@ private static bool TryGetTransformedRectangle(RectangleF rectangle, Matrix3x2 m
439
439
[ MethodImpl ( MethodImplOptions . AggressiveInlining ) ]
440
440
private static bool TryGetTransformedRectangle ( RectangleF rectangle , Matrix4x4 matrix , out Rectangle bounds )
441
441
{
442
- if ( rectangle . Equals ( default ) || Matrix4x4 . Identity . Equals ( matrix ) )
442
+ if ( matrix . IsIdentity || rectangle . Equals ( default ) )
443
443
{
444
444
bounds = default ;
445
445
return false ;
0 commit comments