Chromium Code Reviews| Index: src/gpu/GrPaint.cpp |
| diff --git a/src/gpu/GrPaint.cpp b/src/gpu/GrPaint.cpp |
| new file mode 100644 |
| index 0000000000000000000000000000000000000000..8a1637b14f7ee4bab466ee8a1ded5bb23688a47e |
| --- /dev/null |
| +++ b/src/gpu/GrPaint.cpp |
| @@ -0,0 +1,36 @@ |
| + |
| +/* |
| + * Copyright 2013 Google Inc. |
| + * |
| + * Use of this source code is governed by a BSD-style license that can be |
| + * found in the LICENSE file. |
| + */ |
| + |
| +#include "GrPaint.h" |
| + |
| +#include "effects/GrSimpleTextureEffect.h" |
| + |
| +void GrPaint::addColorTextureEffect(GrTexture* texture, const SkMatrix& matrix) { |
| + GrEffectRef* effect = GrSimpleTextureEffect::Create(texture, matrix); |
| + this->addColorEffect(effect)->unref(); |
| +} |
| + |
| +void GrPaint::addCoverageTextureEffect(GrTexture* texture, const SkMatrix& matrix) { |
| + GrEffectRef* effect = GrSimpleTextureEffect::Create(texture, matrix); |
| + this->addCoverageEffect(effect)->unref(); |
| +} |
| + |
| +void GrPaint::addColorTextureEffect(GrTexture* texture, |
|
robertphillips
2013/07/12 12:54:33
missing space in next two lines?
bsalomon
2013/07/12 13:38:59
Done.
|
| + const SkMatrix& matrix, |
| + const GrTextureParams& params) { |
| + GrEffectRef* effect = GrSimpleTextureEffect::Create(texture, matrix, params); |
| + this->addColorEffect(effect)->unref(); |
| +} |
| + |
| +void GrPaint::addCoverageTextureEffect(GrTexture* texture, |
| + const SkMatrix& matrix, |
| + const GrTextureParams& params) { |
| + GrEffectRef* effect = GrSimpleTextureEffect::Create(texture, matrix, params); |
| + this->addCoverageEffect(effect)->unref(); |
| +} |
| + |