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

Side by Side Diff: src/gpu/gl/builders/GrGLShaderBuilder.cpp

Issue 1037123003: Implement support for KHR_blend_equation_advanced (Closed) Base URL: https://skia.googlesource.com/skia.git@upload_zzz2_barriers
Patch Set: Compiler warning 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/gpu/gl/builders/GrGLFragmentShaderBuilder.cpp ('k') | no next file » | 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 2014 Google Inc. 2 * Copyright 2014 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 "GrGLShaderBuilder.h" 8 #include "GrGLShaderBuilder.h"
9 #include "GrGLProgramBuilder.h" 9 #include "GrGLProgramBuilder.h"
10 #include "GrGLShaderStringBuilder.h" 10 #include "GrGLShaderStringBuilder.h"
(...skipping 155 matching lines...) Expand 10 before | Expand all | Expand 10 after
166 append_texture_lookup(&this->code(), 166 append_texture_lookup(&this->code(),
167 fProgramBuilder->gpu(), 167 fProgramBuilder->gpu(),
168 samplerName, 168 samplerName,
169 coordName, 169 coordName,
170 configComponentMask, 170 configComponentMask,
171 swizzle, 171 swizzle,
172 kVec2f_GrSLType); 172 kVec2f_GrSLType);
173 } 173 }
174 174
175 void GrGLShaderBuilder::addLayoutQualifier(const char* param, InterfaceQualifier interface) { 175 void GrGLShaderBuilder::addLayoutQualifier(const char* param, InterfaceQualifier interface) {
176 SkASSERT(fProgramBuilder->gpu()->glslGeneration() >= k330_GrGLSLGeneration); 176 SkASSERT(fProgramBuilder->gpu()->glslGeneration() >= k330_GrGLSLGeneration | |
177 fProgramBuilder->gpu()->glCaps().glslCaps()->mustEnableAdvBlendEqs( ));
177 fLayoutParams[interface].push_back() = param; 178 fLayoutParams[interface].push_back() = param;
178 } 179 }
179 180
180 void GrGLShaderBuilder::compileAndAppendLayoutQualifiers() { 181 void GrGLShaderBuilder::compileAndAppendLayoutQualifiers() {
181 static const char* interfaceQualifierNames[] = { 182 static const char* interfaceQualifierNames[] = {
182 "out" 183 "out"
183 }; 184 };
184 185
185 for (int interface = 0; interface <= kLastInterfaceQualifier; ++interface) { 186 for (int interface = 0; interface <= kLastInterfaceQualifier; ++interface) {
186 const SkTArray<SkString>& params = fLayoutParams[interface]; 187 const SkTArray<SkString>& params = fLayoutParams[interface];
(...skipping 34 matching lines...) Expand 10 before | Expand all | Expand 10 after
221 fFinalized = true; 222 fFinalized = true;
222 223
223 if (!shaderId) { 224 if (!shaderId) {
224 return false; 225 return false;
225 } 226 }
226 227
227 *shaderIds->append() = shaderId; 228 *shaderIds->append() = shaderId;
228 229
229 return true; 230 return true;
230 } 231 }
OLDNEW
« no previous file with comments | « src/gpu/gl/builders/GrGLFragmentShaderBuilder.cpp ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698