| 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 573 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 584 *grColor = SkColor2GrColorJustAlpha(paint.getColor()); | 584 *grColor = SkColor2GrColorJustAlpha(paint.getColor()); |
| 585 *grEffect = GrRadialGradient::Create(context, *this, matrix, fTileMode); | 585 *grEffect = GrRadialGradient::Create(context, *this, matrix, fTileMode); |
| 586 | 586 |
| 587 return true; | 587 return true; |
| 588 } | 588 } |
| 589 | 589 |
| 590 #else | 590 #else |
| 591 | 591 |
| 592 bool SkRadialGradient::asNewEffect(GrContext* context, const SkPaint& paint, | 592 bool SkRadialGradient::asNewEffect(GrContext* context, const SkPaint& paint, |
| 593 const SkMatrix* localMatrix, GrColor* grColor
, | 593 const SkMatrix* localMatrix, GrColor* grColor
, |
| 594 GrEffect** grEffect) const { | 594 GrEffectRef** grEffect) const { |
| 595 SkDEBUGFAIL("Should not call in GPU-less build"); | 595 SkDEBUGFAIL("Should not call in GPU-less build"); |
| 596 return false; | 596 return false; |
| 597 } | 597 } |
| 598 | 598 |
| 599 #endif | 599 #endif |
| 600 | 600 |
| 601 #ifndef SK_IGNORE_TO_STRING | 601 #ifndef SK_IGNORE_TO_STRING |
| 602 void SkRadialGradient::toString(SkString* str) const { | 602 void SkRadialGradient::toString(SkString* str) const { |
| 603 str->append("SkRadialGradient: ("); | 603 str->append("SkRadialGradient: ("); |
| 604 | 604 |
| 605 str->append("center: ("); | 605 str->append("center: ("); |
| 606 str->appendScalar(fCenter.fX); | 606 str->appendScalar(fCenter.fX); |
| 607 str->append(", "); | 607 str->append(", "); |
| 608 str->appendScalar(fCenter.fY); | 608 str->appendScalar(fCenter.fY); |
| 609 str->append(") radius: "); | 609 str->append(") radius: "); |
| 610 str->appendScalar(fRadius); | 610 str->appendScalar(fRadius); |
| 611 str->append(" "); | 611 str->append(" "); |
| 612 | 612 |
| 613 this->INHERITED::toString(str); | 613 this->INHERITED::toString(str); |
| 614 | 614 |
| 615 str->append(")"); | 615 str->append(")"); |
| 616 } | 616 } |
| 617 #endif | 617 #endif |
| OLD | NEW |