| OLD | NEW | 
|    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 "GrGLProgramBuilder.h" |    8 #include "GrGLProgramBuilder.h" | 
|    9  |    9  | 
|   10 #include "GrAutoLocaleSetter.h" |   10 #include "GrAutoLocaleSetter.h" | 
| (...skipping 403 matching lines...) Expand 10 before | Expand all | Expand 10 after  Loading... | 
|  414         checkLinkStatus(programID); |  414         checkLinkStatus(programID); | 
|  415     } |  415     } | 
|  416     this->resolveProgramResourceLocations(programID); |  416     this->resolveProgramResourceLocations(programID); | 
|  417  |  417  | 
|  418     this->cleanupShaders(shadersToDelete); |  418     this->cleanupShaders(shadersToDelete); | 
|  419  |  419  | 
|  420     return this->createProgram(programID); |  420     return this->createProgram(programID); | 
|  421 } |  421 } | 
|  422  |  422  | 
|  423 void GrGLProgramBuilder::bindProgramResourceLocations(GrGLuint programID) { |  423 void GrGLProgramBuilder::bindProgramResourceLocations(GrGLuint programID) { | 
|  424     bool usingBindUniform = fGpu->glInterface()->fFunctions.fBindUniformLocation
      != nullptr; |  424     if (fGpu->glCaps().bindUniformLocationSupport()) { | 
|  425     if (usingBindUniform) { |  | 
|  426         int count = fUniforms.count(); |  425         int count = fUniforms.count(); | 
|  427         for (int i = 0; i < count; ++i) { |  426         for (int i = 0; i < count; ++i) { | 
|  428             GL_CALL(BindUniformLocation(programID, i, fUniforms[i].fVariable.c_s
     tr())); |  427             GL_CALL(BindUniformLocation(programID, i, fUniforms[i].fVariable.c_s
     tr())); | 
|  429             fUniforms[i].fLocation = i; |  428             fUniforms[i].fLocation = i; | 
|  430         } |  429         } | 
|  431     } |  430     } | 
|  432  |  431  | 
|  433     fFS.bindFragmentShaderLocations(programID); |  432     fFS.bindFragmentShaderLocations(programID); | 
|  434  |  433  | 
|  435     // handle NVPR separable varyings |  434     // handle NVPR separable varyings | 
| (...skipping 79 matching lines...) Expand 10 before | Expand all | Expand 10 after  Loading... | 
|  515 } |  514 } | 
|  516  |  515  | 
|  517 ////////////////////////////////////////////////////////////////////////////////
     /////////////////// |  516 ////////////////////////////////////////////////////////////////////////////////
     /////////////////// | 
|  518  |  517  | 
|  519 GrGLInstalledFragProcs::~GrGLInstalledFragProcs() { |  518 GrGLInstalledFragProcs::~GrGLInstalledFragProcs() { | 
|  520     int numProcs = fProcs.count(); |  519     int numProcs = fProcs.count(); | 
|  521     for (int i = 0; i < numProcs; ++i) { |  520     for (int i = 0; i < numProcs; ++i) { | 
|  522         delete fProcs[i]; |  521         delete fProcs[i]; | 
|  523     } |  522     } | 
|  524 } |  523 } | 
| OLD | NEW |