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

Side by Side Diff: src/effects/gradients/SkLinearGradient.cpp

Issue 2324663004: Remove unneeded GrGLSLTransformedCoordsArray type (Closed)
Patch Set: update comments Created 4 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 unified diff | Download patch
« no previous file with comments | « src/effects/SkPerlinNoiseShader.cpp ('k') | src/effects/gradients/SkRadialGradient.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 "Sk4fLinearGradient.h" 8 #include "Sk4fLinearGradient.h"
9 #include "SkLinearGradient.h" 9 #include "SkLinearGradient.h"
10 #include "SkRefCnt.h" 10 #include "SkRefCnt.h"
(...skipping 419 matching lines...) Expand 10 before | Expand all | Expand 10 after
430 SkSourceGammaTreatment::kRespect)); 430 SkSourceGammaTreatment::kRespect));
431 GrAlwaysAssert(fp); 431 GrAlwaysAssert(fp);
432 return fp; 432 return fp;
433 } 433 }
434 434
435 ///////////////////////////////////////////////////////////////////// 435 /////////////////////////////////////////////////////////////////////
436 436
437 void GrLinearGradient::GLSLLinearProcessor::emitCode(EmitArgs& args) { 437 void GrLinearGradient::GLSLLinearProcessor::emitCode(EmitArgs& args) {
438 const GrLinearGradient& ge = args.fFp.cast<GrLinearGradient>(); 438 const GrLinearGradient& ge = args.fFp.cast<GrLinearGradient>();
439 this->emitUniforms(args.fUniformHandler, ge); 439 this->emitUniforms(args.fUniformHandler, ge);
440 SkString t = args.fFragBuilder->ensureFSCoords2D(args.fCoords, 0); 440 SkString t = args.fFragBuilder->ensureCoords2D(args.fTransformedCoords[0]);
441 t.append(".x"); 441 t.append(".x");
442 this->emitColor(args.fFragBuilder, 442 this->emitColor(args.fFragBuilder,
443 args.fUniformHandler, 443 args.fUniformHandler,
444 args.fGLSLCaps, 444 args.fGLSLCaps,
445 ge, 445 ge,
446 t.c_str(), 446 t.c_str(),
447 args.fOutputColor, 447 args.fOutputColor,
448 args.fInputColor, 448 args.fInputColor,
449 args.fTexSamplers); 449 args.fTexSamplers);
450 } 450 }
(...skipping 309 matching lines...) Expand 10 before | Expand all | Expand 10 after
760 this->shade4_dx_clamp<false, true>(dstC, count, fx, dx, invDx, dithe r); 760 this->shade4_dx_clamp<false, true>(dstC, count, fx, dx, invDx, dithe r);
761 } 761 }
762 } else { 762 } else {
763 if (fApplyAlphaAfterInterp) { 763 if (fApplyAlphaAfterInterp) {
764 this->shade4_dx_clamp<true, false>(dstC, count, fx, dx, invDx, dithe r); 764 this->shade4_dx_clamp<true, false>(dstC, count, fx, dx, invDx, dithe r);
765 } else { 765 } else {
766 this->shade4_dx_clamp<false, false>(dstC, count, fx, dx, invDx, dith er); 766 this->shade4_dx_clamp<false, false>(dstC, count, fx, dx, invDx, dith er);
767 } 767 }
768 } 768 }
769 } 769 }
OLDNEW
« no previous file with comments | « src/effects/SkPerlinNoiseShader.cpp ('k') | src/effects/gradients/SkRadialGradient.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698