| OLD | NEW |
| 1 | 1 |
| 2 /* | 2 /* |
| 3 * Copyright 2006 The Android Open Source Project | 3 * Copyright 2006 The Android Open Source Project |
| 4 * | 4 * |
| 5 * Use of this source code is governed by a BSD-style license that can be | 5 * Use of this source code is governed by a BSD-style license that can be |
| 6 * found in the LICENSE file. | 6 * found in the LICENSE file. |
| 7 */ | 7 */ |
| 8 | 8 |
| 9 | 9 |
| 10 #ifndef SkMatrix_DEFINED | 10 #ifndef SkMatrix_DEFINED |
| (...skipping 331 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 342 */ | 342 */ |
| 343 bool setPolyToPoly(const SkPoint src[], const SkPoint dst[], int count); | 343 bool setPolyToPoly(const SkPoint src[], const SkPoint dst[], int count); |
| 344 | 344 |
| 345 /** If this matrix can be inverted, return true and if inverse is not null, | 345 /** If this matrix can be inverted, return true and if inverse is not null, |
| 346 set inverse to be the inverse of this matrix. If this matrix cannot be | 346 set inverse to be the inverse of this matrix. If this matrix cannot be |
| 347 inverted, ignore inverse and return false | 347 inverted, ignore inverse and return false |
| 348 */ | 348 */ |
| 349 bool SK_WARN_UNUSED_RESULT invert(SkMatrix* inverse) const { | 349 bool SK_WARN_UNUSED_RESULT invert(SkMatrix* inverse) const { |
| 350 // Allow the trivial case to be inlined. | 350 // Allow the trivial case to be inlined. |
| 351 if (this->isIdentity()) { | 351 if (this->isIdentity()) { |
| 352 if (NULL != inverse) { | 352 if (inverse) { |
| 353 inverse->reset(); | 353 inverse->reset(); |
| 354 } | 354 } |
| 355 return true; | 355 return true; |
| 356 } | 356 } |
| 357 return this->invertNonIdentity(inverse); | 357 return this->invertNonIdentity(inverse); |
| 358 } | 358 } |
| 359 | 359 |
| 360 /** Fills the passed array with affine identity values | 360 /** Fills the passed array with affine identity values |
| 361 in column major order. | 361 in column major order. |
| 362 @param affine The array to fill with affine identity values. | 362 @param affine The array to fill with affine identity values. |
| (...skipping 348 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 711 static void RotTrans_pts(const SkMatrix&, SkPoint dst[], const SkPoint[], | 711 static void RotTrans_pts(const SkMatrix&, SkPoint dst[], const SkPoint[], |
| 712 int count); | 712 int count); |
| 713 static void Persp_pts(const SkMatrix&, SkPoint dst[], const SkPoint[], int); | 713 static void Persp_pts(const SkMatrix&, SkPoint dst[], const SkPoint[], int); |
| 714 | 714 |
| 715 static const MapPtsProc gMapPtsProcs[]; | 715 static const MapPtsProc gMapPtsProcs[]; |
| 716 | 716 |
| 717 friend class SkPerspIter; | 717 friend class SkPerspIter; |
| 718 }; | 718 }; |
| 719 | 719 |
| 720 #endif | 720 #endif |
| OLD | NEW |