| 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 "SkTwoPointConicalGradient.h" | 9 #include "SkTwoPointConicalGradient.h" |
| 10 | 10 |
| (...skipping 428 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 439 | 439 |
| 440 // @} | 440 // @} |
| 441 | 441 |
| 442 typedef GrGradientEffect INHERITED; | 442 typedef GrGradientEffect INHERITED; |
| 443 }; | 443 }; |
| 444 | 444 |
| 445 GR_DEFINE_EFFECT_TEST(GrConical2Gradient); | 445 GR_DEFINE_EFFECT_TEST(GrConical2Gradient); |
| 446 | 446 |
| 447 GrEffectRef* GrConical2Gradient::TestCreate(SkMWCRandom* random, | 447 GrEffectRef* GrConical2Gradient::TestCreate(SkMWCRandom* random, |
| 448 GrContext* context, | 448 GrContext* context, |
| 449 const GrDrawTargetCaps&, |
| 449 GrTexture**) { | 450 GrTexture**) { |
| 450 SkPoint center1 = {random->nextUScalar1(), random->nextUScalar1()}; | 451 SkPoint center1 = {random->nextUScalar1(), random->nextUScalar1()}; |
| 451 SkScalar radius1 = random->nextUScalar1(); | 452 SkScalar radius1 = random->nextUScalar1(); |
| 452 SkPoint center2; | 453 SkPoint center2; |
| 453 SkScalar radius2; | 454 SkScalar radius2; |
| 454 do { | 455 do { |
| 455 center2.set(random->nextUScalar1(), random->nextUScalar1()); | 456 center2.set(random->nextUScalar1(), random->nextUScalar1()); |
| 456 radius2 = random->nextUScalar1 (); | 457 radius2 = random->nextUScalar1 (); |
| 457 // If the circles are identical the factory will give us an empty shader
. | 458 // If the circles are identical the factory will give us an empty shader
. |
| 458 } while (radius1 == radius2 && center1 == center2); | 459 } while (radius1 == radius2 && center1 == center2); |
| (...skipping 298 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 757 str->appendScalar(fCenter2.fY); | 758 str->appendScalar(fCenter2.fY); |
| 758 str->append(") radius2: "); | 759 str->append(") radius2: "); |
| 759 str->appendScalar(fRadius2); | 760 str->appendScalar(fRadius2); |
| 760 str->append(" "); | 761 str->append(" "); |
| 761 | 762 |
| 762 this->INHERITED::toString(str); | 763 this->INHERITED::toString(str); |
| 763 | 764 |
| 764 str->append(")"); | 765 str->append(")"); |
| 765 } | 766 } |
| 766 #endif | 767 #endif |
| OLD | NEW |