| OLD | NEW |
| 1 | 1 |
| 2 /* | 2 /* |
| 3 * Copyright 2012 Google Inc. | 3 * Copyright 2012 Google Inc. |
| 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 #include "SkRadialGradient.h" | 9 #include "SkRadialGradient.h" |
| 10 #include "SkRadialGradient_Table.h" | 10 #include "SkRadialGradient_Table.h" |
| (...skipping 515 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 526 if (localMatrix) { | 526 if (localMatrix) { |
| 527 SkMatrix inv; | 527 SkMatrix inv; |
| 528 if (!localMatrix->invert(&inv)) { | 528 if (!localMatrix->invert(&inv)) { |
| 529 return nullptr; | 529 return nullptr; |
| 530 } | 530 } |
| 531 matrix.postConcat(inv); | 531 matrix.postConcat(inv); |
| 532 } | 532 } |
| 533 matrix.postConcat(fPtsToUnit); | 533 matrix.postConcat(fPtsToUnit); |
| 534 SkAutoTUnref<const GrFragmentProcessor> inner( | 534 SkAutoTUnref<const GrFragmentProcessor> inner( |
| 535 GrRadialGradient::Create(context, procDataManager, *this, matrix, fT
ileMode)); | 535 GrRadialGradient::Create(context, procDataManager, *this, matrix, fT
ileMode)); |
| 536 return GrFragmentProcessor::MulOuputByInputAlpha(inner); | 536 return GrFragmentProcessor::MulOutputByInputAlpha(inner); |
| 537 } | 537 } |
| 538 | 538 |
| 539 #endif | 539 #endif |
| 540 | 540 |
| 541 #ifndef SK_IGNORE_TO_STRING | 541 #ifndef SK_IGNORE_TO_STRING |
| 542 void SkRadialGradient::toString(SkString* str) const { | 542 void SkRadialGradient::toString(SkString* str) const { |
| 543 str->append("SkRadialGradient: ("); | 543 str->append("SkRadialGradient: ("); |
| 544 | 544 |
| 545 str->append("center: ("); | 545 str->append("center: ("); |
| 546 str->appendScalar(fCenter.fX); | 546 str->appendScalar(fCenter.fX); |
| 547 str->append(", "); | 547 str->append(", "); |
| 548 str->appendScalar(fCenter.fY); | 548 str->appendScalar(fCenter.fY); |
| 549 str->append(") radius: "); | 549 str->append(") radius: "); |
| 550 str->appendScalar(fRadius); | 550 str->appendScalar(fRadius); |
| 551 str->append(" "); | 551 str->append(" "); |
| 552 | 552 |
| 553 this->INHERITED::toString(str); | 553 this->INHERITED::toString(str); |
| 554 | 554 |
| 555 str->append(")"); | 555 str->append(")"); |
| 556 } | 556 } |
| 557 #endif | 557 #endif |
| OLD | NEW |