Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(284)

Unified Diff: src/gpu/effects/GrSimpleTextureEffect.cpp

Issue 582963002: Solo gp (Closed) Base URL: https://skia.googlesource.com/skia.git@no_peb
Patch Set: rebase Created 6 years, 3 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « src/gpu/effects/GrSimpleTextureEffect.h ('k') | src/gpu/effects/GrSingleTextureEffect.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/gpu/effects/GrSimpleTextureEffect.cpp
diff --git a/src/gpu/effects/GrSimpleTextureEffect.cpp b/src/gpu/effects/GrSimpleTextureEffect.cpp
index f2a932b02b8b3fa7d337775beebf3dcdd2b761af..6743ddbbe1119d5647ed9104077120c234515fb4 100644
--- a/src/gpu/effects/GrSimpleTextureEffect.cpp
+++ b/src/gpu/effects/GrSimpleTextureEffect.cpp
@@ -7,21 +7,21 @@
#include "gl/builders/GrGLProgramBuilder.h"
#include "GrSimpleTextureEffect.h"
-#include "gl/GrGLEffect.h"
+#include "gl/GrGLProcessor.h"
#include "gl/GrGLSL.h"
#include "gl/GrGLTexture.h"
-#include "GrTBackendEffectFactory.h"
+#include "GrTBackendProcessorFactory.h"
#include "GrTexture.h"
-class GrGLSimpleTextureEffect : public GrGLEffect {
+class GrGLSimpleTextureEffect : public GrGLFragmentProcessor {
public:
- GrGLSimpleTextureEffect(const GrBackendEffectFactory& factory, const GrEffect&)
+ GrGLSimpleTextureEffect(const GrBackendProcessorFactory& factory, const GrProcessor&)
: INHERITED (factory) {
}
virtual void emitCode(GrGLProgramBuilder* builder,
- const GrEffect& effect,
- const GrEffectKey& key,
+ const GrFragmentProcessor& fp,
+ const GrProcessorKey& key,
const char* outputColor,
const char* inputColor,
const TransformedCoordsArray& coords,
@@ -36,7 +36,7 @@ public:
}
private:
- typedef GrGLEffect INHERITED;
+ typedef GrGLFragmentProcessor INHERITED;
};
///////////////////////////////////////////////////////////////////////////////
@@ -45,20 +45,20 @@ void GrSimpleTextureEffect::getConstantColorComponents(GrColor* color, uint32_t*
this->updateConstantColorComponentsForModulation(color, validFlags);
}
-const GrBackendEffectFactory& GrSimpleTextureEffect::getFactory() const {
- return GrTBackendEffectFactory<GrSimpleTextureEffect>::getInstance();
+const GrBackendFragmentProcessorFactory& GrSimpleTextureEffect::getFactory() const {
+ return GrTBackendFragmentProcessorFactory<GrSimpleTextureEffect>::getInstance();
}
///////////////////////////////////////////////////////////////////////////////
-GR_DEFINE_EFFECT_TEST(GrSimpleTextureEffect);
+GR_DEFINE_FRAGMENT_PROCESSOR_TEST(GrSimpleTextureEffect);
-GrEffect* GrSimpleTextureEffect::TestCreate(SkRandom* random,
- GrContext*,
- const GrDrawTargetCaps&,
- GrTexture* textures[]) {
- int texIdx = random->nextBool() ? GrEffectUnitTest::kSkiaPMTextureIdx :
- GrEffectUnitTest::kAlphaTextureIdx;
+GrFragmentProcessor* GrSimpleTextureEffect::TestCreate(SkRandom* random,
+ GrContext*,
+ const GrDrawTargetCaps&,
+ GrTexture* textures[]) {
+ int texIdx = random->nextBool() ? GrProcessorUnitTest::kSkiaPMTextureIdx :
+ GrProcessorUnitTest::kAlphaTextureIdx;
static const SkShader::TileMode kTileModes[] = {
SkShader::kClamp_TileMode,
SkShader::kRepeat_TileMode,
@@ -77,6 +77,6 @@ GrEffect* GrSimpleTextureEffect::TestCreate(SkRandom* random,
};
GrCoordSet coordSet = kCoordSets[random->nextULessThan(SK_ARRAY_COUNT(kCoordSets))];
- const SkMatrix& matrix = GrEffectUnitTest::TestMatrix(random);
+ const SkMatrix& matrix = GrProcessorUnitTest::TestMatrix(random);
return GrSimpleTextureEffect::Create(textures[texIdx], matrix, coordSet);
}
« no previous file with comments | « src/gpu/effects/GrSimpleTextureEffect.h ('k') | src/gpu/effects/GrSingleTextureEffect.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698