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

Side by Side Diff: src/gpu/gl/GrGLProgramDesc.h

Issue 212753002: Use fixed function pipeline only when drawing paths (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: rebase Created 6 years, 8 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/GrGLProgram.cpp ('k') | src/gpu/gl/GrGLProgramDesc.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 #ifndef GrGLProgramDesc_DEFINED 8 #ifndef GrGLProgramDesc_DEFINED
9 #define GrGLProgramDesc_DEFINED 9 #define GrGLProgramDesc_DEFINED
10 10
11 #include "GrGLEffect.h" 11 #include "GrGLEffect.h"
12 #include "GrDrawState.h" 12 #include "GrDrawState.h"
13 #include "GrGLShaderBuilder.h" 13 #include "GrGLShaderBuilder.h"
14 #include "GrGpu.h"
14 15
15 class GrGpuGL; 16 class GrGpuGL;
16 17
17 #ifdef SK_DEBUG 18 #ifdef SK_DEBUG
18 // Optionally compile the experimental GS code. Set to SK_DEBUG so that debug build bots will 19 // Optionally compile the experimental GS code. Set to SK_DEBUG so that debug build bots will
19 // execute the code. 20 // execute the code.
20 #define GR_GL_EXPERIMENTAL_GS 1 21 #define GR_GL_EXPERIMENTAL_GS 1
21 #else 22 #else
22 #define GR_GL_EXPERIMENTAL_GS 0 23 #define GR_GL_EXPERIMENTAL_GS 0
23 #endif 24 #endif
(...skipping 33 matching lines...) Expand 10 before | Expand all | Expand 10 after
57 int currAttribIndex); 58 int currAttribIndex);
58 59
59 /** 60 /**
60 * Builds a program descriptor from a GrDrawState. Whether the primitive typ e is points, the 61 * Builds a program descriptor from a GrDrawState. Whether the primitive typ e is points, the
61 * output of GrDrawState::getBlendOpts, and the caps of the GrGpuGL are also inputs. It also 62 * output of GrDrawState::getBlendOpts, and the caps of the GrGpuGL are also inputs. It also
62 * outputs the color and coverage stages referenced by the generated descrip tor. This may 63 * outputs the color and coverage stages referenced by the generated descrip tor. This may
63 * not contain all stages from the draw state and coverage stages from the d rawState may 64 * not contain all stages from the draw state and coverage stages from the d rawState may
64 * be treated as color stages in the output. 65 * be treated as color stages in the output.
65 */ 66 */
66 static void Build(const GrDrawState&, 67 static void Build(const GrDrawState&,
67 bool isPoints, 68 GrGpu::DrawType drawType,
68 GrDrawState::BlendOptFlags, 69 GrDrawState::BlendOptFlags,
69 GrBlendCoeff srcCoeff, 70 GrBlendCoeff srcCoeff,
70 GrBlendCoeff dstCoeff, 71 GrBlendCoeff dstCoeff,
71 const GrGpuGL* gpu, 72 const GrGpuGL* gpu,
72 const GrDeviceCoordTexture* dstCopy, 73 const GrDeviceCoordTexture* dstCopy,
73 SkTArray<const GrEffectStage*, true>* outColorStages, 74 SkTArray<const GrEffectStage*, true>* outColorStages,
74 SkTArray<const GrEffectStage*, true>* outCoverageStages, 75 SkTArray<const GrEffectStage*, true>* outCoverageStages,
75 GrGLProgramDesc* outDesc); 76 GrGLProgramDesc* outDesc);
76 77
77 int numColorEffects() const { 78 int numColorEffects() const {
(...skipping 137 matching lines...) Expand 10 before | Expand all | Expand 10 after
215 216
216 // GrGLProgram and GrGLShaderBuilder read the private fields to generate cod e. TODO: Move all 217 // GrGLProgram and GrGLShaderBuilder read the private fields to generate cod e. TODO: Move all
217 // code generation to GrGLShaderBuilder (and maybe add getters rather than f riending). 218 // code generation to GrGLShaderBuilder (and maybe add getters rather than f riending).
218 friend class GrGLProgram; 219 friend class GrGLProgram;
219 friend class GrGLShaderBuilder; 220 friend class GrGLShaderBuilder;
220 friend class GrGLFullShaderBuilder; 221 friend class GrGLFullShaderBuilder;
221 friend class GrGLFragmentOnlyShaderBuilder; 222 friend class GrGLFragmentOnlyShaderBuilder;
222 }; 223 };
223 224
224 #endif 225 #endif
OLDNEW
« no previous file with comments | « src/gpu/gl/GrGLProgram.cpp ('k') | src/gpu/gl/GrGLProgramDesc.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698