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

Side by Side Diff: src/effects/SkPerlinNoiseShader.cpp

Issue 1110033004: Make XPFragmentBuilder only Builder with access to DstCopy. (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: Created 5 years, 7 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/SkMorphologyImageFilter.cpp ('k') | src/effects/SkTableColorFilter.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 2013 Google Inc. 2 * Copyright 2013 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 "SkDither.h" 8 #include "SkDither.h"
9 #include "SkPerlinNoiseShader.h" 9 #include "SkPerlinNoiseShader.h"
10 #include "SkColorFilter.h" 10 #include "SkColorFilter.h"
(...skipping 629 matching lines...) Expand 10 before | Expand all | Expand 10 after
640 } 640 }
641 641
642 void GrGLPerlinNoise::emitCode(GrGLFPBuilder* builder, 642 void GrGLPerlinNoise::emitCode(GrGLFPBuilder* builder,
643 const GrFragmentProcessor&, 643 const GrFragmentProcessor&,
644 const char* outputColor, 644 const char* outputColor,
645 const char* inputColor, 645 const char* inputColor,
646 const TransformedCoordsArray& coords, 646 const TransformedCoordsArray& coords,
647 const TextureSamplerArray& samplers) { 647 const TextureSamplerArray& samplers) {
648 sk_ignore_unused_variable(inputColor); 648 sk_ignore_unused_variable(inputColor);
649 649
650 GrGLFPFragmentBuilder* fsBuilder = builder->getFragmentShaderBuilder(); 650 GrGLFragmentBuilder* fsBuilder = builder->getFragmentShaderBuilder();
651 SkString vCoords = fsBuilder->ensureFSCoords2D(coords, 0); 651 SkString vCoords = fsBuilder->ensureFSCoords2D(coords, 0);
652 652
653 fBaseFrequencyUni = builder->addUniform(GrGLProgramBuilder::kFragment_Visibi lity, 653 fBaseFrequencyUni = builder->addUniform(GrGLProgramBuilder::kFragment_Visibi lity,
654 kVec2f_GrSLType, kDefault_GrSLPrecis ion, 654 kVec2f_GrSLType, kDefault_GrSLPrecis ion,
655 "baseFrequency"); 655 "baseFrequency");
656 const char* baseFrequencyUni = builder->getUniformCStr(fBaseFrequencyUni); 656 const char* baseFrequencyUni = builder->getUniformCStr(fBaseFrequencyUni);
657 fAlphaUni = builder->addUniform(GrGLProgramBuilder::kFragment_Visibility, 657 fAlphaUni = builder->addUniform(GrGLProgramBuilder::kFragment_Visibility,
658 kFloat_GrSLType, kDefault_GrSLPrecision, 658 kFloat_GrSLType, kDefault_GrSLPrecision,
659 "alpha"); 659 "alpha");
660 const char* alphaUni = builder->getUniformCStr(fAlphaUni); 660 const char* alphaUni = builder->getUniformCStr(fAlphaUni);
(...skipping 371 matching lines...) Expand 10 before | Expand all | Expand 10 after
1032 str->append(" seed: "); 1032 str->append(" seed: ");
1033 str->appendScalar(fSeed); 1033 str->appendScalar(fSeed);
1034 str->append(" stitch tiles: "); 1034 str->append(" stitch tiles: ");
1035 str->append(fStitchTiles ? "true " : "false "); 1035 str->append(fStitchTiles ? "true " : "false ");
1036 1036
1037 this->INHERITED::toString(str); 1037 this->INHERITED::toString(str);
1038 1038
1039 str->append(")"); 1039 str->append(")");
1040 } 1040 }
1041 #endif 1041 #endif
OLDNEW
« no previous file with comments | « src/effects/SkMorphologyImageFilter.cpp ('k') | src/effects/SkTableColorFilter.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698