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

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

Issue 1307223004: Remove GrStagedProcessor, remove the word Stage as it applies to FPs (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: fix misresolve Created 5 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/gpu/gl/GrGLProgramDesc.cpp ('k') | src/gpu/gl/builders/GrGLProgramBuilder.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 #ifndef GrGLProgramBuilder_DEFINED 8 #ifndef GrGLProgramBuilder_DEFINED
9 #define GrGLProgramBuilder_DEFINED 9 #define GrGLProgramBuilder_DEFINED
10 10
11 #include "GrGLFragmentShaderBuilder.h" 11 #include "GrGLFragmentShaderBuilder.h"
12 #include "GrGLGeometryShaderBuilder.h" 12 #include "GrGLGeometryShaderBuilder.h"
13 #include "GrGLVertexShaderBuilder.h" 13 #include "GrGLVertexShaderBuilder.h"
14 #include "../GrGLProgramDataManager.h" 14 #include "../GrGLProgramDataManager.h"
15 #include "../GrGLPathProgramDataManager.h" 15 #include "../GrGLPathProgramDataManager.h"
16 #include "../GrGLUniformHandle.h" 16 #include "../GrGLUniformHandle.h"
17 #include "../GrGLPrimitiveProcessor.h" 17 #include "../GrGLPrimitiveProcessor.h"
18 #include "../GrGLXferProcessor.h" 18 #include "../GrGLXferProcessor.h"
19 #include "../../GrPendingFragmentStage.h"
20 #include "../../GrPipeline.h" 19 #include "../../GrPipeline.h"
21 20
21 class GrFragmentProcessor;
22
22 // Enough precision to represent 1 / 2048 accurately in printf 23 // Enough precision to represent 1 / 2048 accurately in printf
23 #define GR_SIGNIFICANT_POW2_DECIMAL_DIG 11 24 #define GR_SIGNIFICANT_POW2_DECIMAL_DIG 11
24 25
25 /* 26 /*
26 * This is the base class for a series of interfaces. This base class *MUST* re main abstract with 27 * This is the base class for a series of interfaces. This base class *MUST* re main abstract with
27 * NO data members because it is used in multiple interface inheritance. 28 * NO data members because it is used in multiple interface inheritance.
28 * Heirarchy: 29 * Heirarchy:
29 * GrGLUniformBuilder 30 * GrGLUniformBuilder
30 * / \ 31 * / \
31 * GrGLFPBuilder GrGLGPBuilder 32 * GrGLFPBuilder GrGLGPBuilder
(...skipping 262 matching lines...) Expand 10 before | Expand all | Expand 10 after
294 295
295 // Generates a name for a variable. The generated string will be name prefix ed by the prefix 296 // Generates a name for a variable. The generated string will be name prefix ed by the prefix
296 // char (unless the prefix is '\0'). It also mangles the name to be stage-sp ecific if we're 297 // char (unless the prefix is '\0'). It also mangles the name to be stage-sp ecific if we're
297 // generating stage code. 298 // generating stage code.
298 void nameVariable(SkString* out, char prefix, const char* name); 299 void nameVariable(SkString* out, char prefix, const char* name);
299 // Generates a possibly mangled name for a stage variable and writes it to t he fragment shader. 300 // Generates a possibly mangled name for a stage variable and writes it to t he fragment shader.
300 // If GrGLSLExpr4 has a valid name then it will use that instead 301 // If GrGLSLExpr4 has a valid name then it will use that instead
301 void nameExpression(GrGLSLExpr4*, const char* baseName); 302 void nameExpression(GrGLSLExpr4*, const char* baseName);
302 bool emitAndInstallProcs(GrGLSLExpr4* inputColor, GrGLSLExpr4* inputCoverage ); 303 bool emitAndInstallProcs(GrGLSLExpr4* inputColor, GrGLSLExpr4* inputCoverage );
303 void emitAndInstallFragProcs(int procOffset, int numProcs, GrGLSLExpr4* inOu t); 304 void emitAndInstallFragProcs(int procOffset, int numProcs, GrGLSLExpr4* inOu t);
304 void emitAndInstallProc(const GrPendingFragmentStage&, 305 void emitAndInstallProc(const GrFragmentProcessor&,
305 int index, 306 int index,
306 const GrGLSLExpr4& input, 307 const GrGLSLExpr4& input,
307 GrGLSLExpr4* output); 308 GrGLSLExpr4* output);
308 309
309 void emitAndInstallProc(const GrPrimitiveProcessor&, 310 void emitAndInstallProc(const GrPrimitiveProcessor&,
310 GrGLSLExpr4* outputColor, 311 GrGLSLExpr4* outputColor,
311 GrGLSLExpr4* outputCoverage); 312 GrGLSLExpr4* outputCoverage);
312 313
313 // these emit functions help to keep the createAndEmitProcessors template ge neral 314 // these emit functions help to keep the createAndEmitProcessors template ge neral
314 void emitAndInstallProc(const GrPendingFragmentStage&, 315 void emitAndInstallProc(const GrFragmentProcessor&,
315 int index, 316 int index,
316 const char* outColor, 317 const char* outColor,
317 const char* inColor); 318 const char* inColor);
318 void emitAndInstallProc(const GrPrimitiveProcessor&, 319 void emitAndInstallProc(const GrPrimitiveProcessor&,
319 const char* outColor, 320 const char* outColor,
320 const char* outCoverage); 321 const char* outCoverage);
321 void emitAndInstallXferProc(const GrXferProcessor&, 322 void emitAndInstallXferProc(const GrXferProcessor&,
322 const GrGLSLExpr4& colorIn, 323 const GrGLSLExpr4& colorIn,
323 const GrGLSLExpr4& coverageIn); 324 const GrGLSLExpr4& coverageIn);
324 325
(...skipping 75 matching lines...) Expand 10 before | Expand all | Expand 10 after
400 GrGLPrimitiveProcessor::TransformsIn fCoordTransforms; 401 GrGLPrimitiveProcessor::TransformsIn fCoordTransforms;
401 GrGLPrimitiveProcessor::TransformsOut fOutCoords; 402 GrGLPrimitiveProcessor::TransformsOut fOutCoords;
402 SkTArray<UniformHandle> fSamplerUniforms; 403 SkTArray<UniformHandle> fSamplerUniforms;
403 404
404 friend class GrGLShaderBuilder; 405 friend class GrGLShaderBuilder;
405 friend class GrGLVertexBuilder; 406 friend class GrGLVertexBuilder;
406 friend class GrGLFragmentShaderBuilder; 407 friend class GrGLFragmentShaderBuilder;
407 friend class GrGLGeometryBuilder; 408 friend class GrGLGeometryBuilder;
408 }; 409 };
409 #endif 410 #endif
OLDNEW
« no previous file with comments | « src/gpu/gl/GrGLProgramDesc.cpp ('k') | src/gpu/gl/builders/GrGLProgramBuilder.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698