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

Unified Diff: src/effects/SkMagnifierImageFilter.cpp

Issue 1428543003: Create GLSL base class for ProgramDataManager (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: add space Created 5 years, 2 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/effects/SkLightingImageFilter.cpp ('k') | src/effects/SkMorphologyImageFilter.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/effects/SkMagnifierImageFilter.cpp
diff --git a/src/effects/SkMagnifierImageFilter.cpp b/src/effects/SkMagnifierImageFilter.cpp
index 903f34ca147cd76fa428d4ced96f9afc383e0fb2..c7d3d5ae2d1a48ceefa471ca09fb22498ea54ca6 100644
--- a/src/effects/SkMagnifierImageFilter.cpp
+++ b/src/effects/SkMagnifierImageFilter.cpp
@@ -20,6 +20,7 @@
#include "gl/GrGLFragmentProcessor.h"
#include "gl/GrGLTexture.h"
#include "gl/builders/GrGLProgramBuilder.h"
+#include "glsl/GrGLSLProgramDataManager.h"
class GrMagnifierEffect : public GrSingleTextureEffect {
@@ -95,7 +96,7 @@ private:
};
// For brevity
-typedef GrGLProgramDataManager::UniformHandle UniformHandle;
+typedef GrGLSLProgramDataManager::UniformHandle UniformHandle;
class GrGLMagnifierEffect : public GrGLFragmentProcessor {
public:
@@ -104,7 +105,7 @@ public:
virtual void emitCode(EmitArgs&) override;
protected:
- void onSetData(const GrGLProgramDataManager&, const GrProcessor&) override;
+ void onSetData(const GrGLSLProgramDataManager&, const GrProcessor&) override;
private:
UniformHandle fOffsetVar;
@@ -171,8 +172,8 @@ void GrGLMagnifierEffect::emitCode(EmitArgs& args) {
fsBuilder->codeAppend(modulate.c_str());
}
-void GrGLMagnifierEffect::onSetData(const GrGLProgramDataManager& pdman,
- const GrProcessor& effect) {
+void GrGLMagnifierEffect::onSetData(const GrGLSLProgramDataManager& pdman,
+ const GrProcessor& effect) {
const GrMagnifierEffect& zoom = effect.cast<GrMagnifierEffect>();
pdman.set2f(fOffsetVar, zoom.x_offset(), zoom.y_offset());
pdman.set2f(fInvZoomVar, zoom.x_inv_zoom(), zoom.y_inv_zoom());
« no previous file with comments | « src/effects/SkLightingImageFilter.cpp ('k') | src/effects/SkMorphologyImageFilter.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698