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

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

Issue 1012723002: Use C locale for numerics when emitting shaders. (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: fix mac includes Created 5 years, 9 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 | « include/gpu/GrTypesPriv.h ('k') | tests/GLProgramsTest.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 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 "gl/GrGLGeometryProcessor.h" 10 #include "gl/GrGLGeometryProcessor.h"
(...skipping 35 matching lines...) Expand 10 before | Expand all | Expand 10 after
46 typedef GrGLProgramBuilder INHERITED; 46 typedef GrGLProgramBuilder INHERITED;
47 }; 47 };
48 48
49 49
50 50
51 ////////////////////////////////////////////////////////////////////////////// 51 //////////////////////////////////////////////////////////////////////////////
52 52
53 const int GrGLProgramBuilder::kVarsPerBlock = 8; 53 const int GrGLProgramBuilder::kVarsPerBlock = 8;
54 54
55 GrGLProgram* GrGLProgramBuilder::CreateProgram(const DrawArgs& args, GrGLGpu* gp u) { 55 GrGLProgram* GrGLProgramBuilder::CreateProgram(const DrawArgs& args, GrGLGpu* gp u) {
56 GrAutoLocaleSetter als("C");
57
56 // create a builder. This will be handed off to effects so they can use it to add 58 // create a builder. This will be handed off to effects so they can use it to add
57 // uniforms, varyings, textures, etc 59 // uniforms, varyings, textures, etc
58 SkAutoTDelete<GrGLProgramBuilder> builder(CreateProgramBuilder(args, gpu)); 60 SkAutoTDelete<GrGLProgramBuilder> builder(CreateProgramBuilder(args, gpu));
59 61
60 GrGLProgramBuilder* pb = builder.get(); 62 GrGLProgramBuilder* pb = builder.get();
61 63
62 // TODO: Once all stages can handle taking a float or vec4 and correctly han dling them we can 64 // TODO: Once all stages can handle taking a float or vec4 and correctly han dling them we can
63 // seed correctly here 65 // seed correctly here
64 GrGLSLExpr4 inputColor; 66 GrGLSLExpr4 inputColor;
65 GrGLSLExpr4 inputCoverage; 67 GrGLSLExpr4 inputCoverage;
(...skipping 427 matching lines...) Expand 10 before | Expand all | Expand 10 after
493 } 495 }
494 496
495 //////////////////////////////////////////////////////////////////////////////// /////////////////// 497 //////////////////////////////////////////////////////////////////////////////// ///////////////////
496 498
497 GrGLInstalledFragProcs::~GrGLInstalledFragProcs() { 499 GrGLInstalledFragProcs::~GrGLInstalledFragProcs() {
498 int numProcs = fProcs.count(); 500 int numProcs = fProcs.count();
499 for (int e = 0; e < numProcs; ++e) { 501 for (int e = 0; e < numProcs; ++e) {
500 SkDELETE(fProcs[e]); 502 SkDELETE(fProcs[e]);
501 } 503 }
502 } 504 }
OLDNEW
« no previous file with comments | « include/gpu/GrTypesPriv.h ('k') | tests/GLProgramsTest.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698