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

Side by Side Diff: src/gpu/effects/GrConfigConversionEffect.cpp

Issue 1266633003: Added registerChild; transforms, textures, glKey automatically handled. (Closed) Base URL: https://skia.googlesource.com/skia@master
Patch Set: refactored to onGetGLProcessorKey; removed emitSamplers specialized template; fixed nits Created 5 years, 4 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 unified diff | Download patch
« no previous file with comments | « src/gpu/effects/GrConfigConversionEffect.h ('k') | src/gpu/effects/GrConstColorProcessor.cpp » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 /* 1 /*
2 * Copyright 2012 Google Inc. 2 * Copyright 2012 Google Inc.
3 * 3 *
4 * Use of this source code is governed by a BSD-style license that can be 4 * Use of this source code is governed by a BSD-style license that can be
5 * found in the LICENSE file. 5 * found in the LICENSE file.
6 */ 6 */
7 7
8 #include "GrConfigConversionEffect.h" 8 #include "GrConfigConversionEffect.h"
9 #include "GrContext.h" 9 #include "GrContext.h"
10 #include "GrDrawContext.h" 10 #include "GrDrawContext.h"
(...skipping 125 matching lines...) Expand 10 before | Expand all | Expand 10 after
136 return SkNEW_ARGS(GrConfigConversionEffect, 136 return SkNEW_ARGS(GrConfigConversionEffect,
137 (d->fProcDataManager, 137 (d->fProcDataManager,
138 d->fTextures[GrProcessorUnitTest::kSkiaPM TextureIdx], 138 d->fTextures[GrProcessorUnitTest::kSkiaPM TextureIdx],
139 swapRB, 139 swapRB,
140 pmConv, 140 pmConv,
141 GrTest::TestMatrix(d->fRandom))); 141 GrTest::TestMatrix(d->fRandom)));
142 } 142 }
143 143
144 /////////////////////////////////////////////////////////////////////////////// 144 ///////////////////////////////////////////////////////////////////////////////
145 145
146 void GrConfigConversionEffect::getGLProcessorKey(const GrGLSLCaps& caps, 146 void GrConfigConversionEffect::onGetGLProcessorKey(const GrGLSLCaps& caps,
147 GrProcessorKeyBuilder* b) const { 147 GrProcessorKeyBuilder* b) const {
148 GrGLConfigConversionEffect::GenKey(*this, caps, b); 148 GrGLConfigConversionEffect::GenKey(*this, caps, b);
149 } 149 }
150 150
151 GrGLFragmentProcessor* GrConfigConversionEffect::createGLInstance() const { 151 GrGLFragmentProcessor* GrConfigConversionEffect::createGLInstance() const {
152 return SkNEW_ARGS(GrGLConfigConversionEffect, (*this)); 152 return SkNEW_ARGS(GrGLConfigConversionEffect, (*this));
153 } 153 }
154 154
155 155
156 156
(...skipping 154 matching lines...) Expand 10 before | Expand all | Expand 10 after
311 // The PM conversions assume colors are 0..255 311 // The PM conversions assume colors are 0..255
312 return NULL; 312 return NULL;
313 } 313 }
314 return SkNEW_ARGS(GrConfigConversionEffect, (procDataManager, 314 return SkNEW_ARGS(GrConfigConversionEffect, (procDataManager,
315 texture, 315 texture,
316 swapRedAndBlue, 316 swapRedAndBlue,
317 pmConversion, 317 pmConversion,
318 matrix)); 318 matrix));
319 } 319 }
320 } 320 }
OLDNEW
« no previous file with comments | « src/gpu/effects/GrConfigConversionEffect.h ('k') | src/gpu/effects/GrConstColorProcessor.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698