OLD | NEW |
1 /* | 1 /* |
2 * Copyright 2011 Google Inc. | 2 * Copyright 2011 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 | 8 |
9 #ifndef GrGLProgram_DEFINED | 9 #ifndef GrGLProgram_DEFINED |
10 #define GrGLProgram_DEFINED | 10 #define GrGLProgram_DEFINED |
(...skipping 102 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
113 GrGLuint programID, | 113 GrGLuint programID, |
114 const UniformInfoArray&, | 114 const UniformInfoArray&, |
115 const SkTArray<GrGLSampler>&, | 115 const SkTArray<GrGLSampler>&, |
116 const VaryingInfoArray&, // used for NVPR only currently | 116 const VaryingInfoArray&, // used for NVPR only currently |
117 GrGLSLPrimitiveProcessor* geometryProcessor, | 117 GrGLSLPrimitiveProcessor* geometryProcessor, |
118 GrGLSLXferProcessor* xferProcessor, | 118 GrGLSLXferProcessor* xferProcessor, |
119 const GrGLSLFragProcs& fragmentProcessors); | 119 const GrGLSLFragProcs& fragmentProcessors); |
120 | 120 |
121 // A helper to loop over effects, set the transforms (via subclass) and bind
textures | 121 // A helper to loop over effects, set the transforms (via subclass) and bind
textures |
122 void setFragmentData(const GrPrimitiveProcessor&, const GrPipeline&, int* ne
xtSamplerIdx); | 122 void setFragmentData(const GrPrimitiveProcessor&, const GrPipeline&, int* ne
xtSamplerIdx); |
| 123 void setTransformData(const GrPrimitiveProcessor&, const GrFragmentProcessor
&, int index); |
123 | 124 |
124 // Helper for setData() that sets the view matrix and loads the render targe
t height uniform | 125 // Helper for setData() that sets the view matrix and loads the render targe
t height uniform |
125 void setRenderTargetState(const GrPrimitiveProcessor&, const GrPipeline&); | 126 void setRenderTargetState(const GrPrimitiveProcessor&, const GrPipeline&); |
126 | 127 |
127 // Helper for setData() that binds textures and texel buffers to the appropr
iate texture units | 128 // Helper for setData() that binds textures and texel buffers to the appropr
iate texture units |
128 void bindTextures(const GrProcessor&, bool allowSRGBInputs, int* nextSampler
Idx); | 129 void bindTextures(const GrProcessor&, bool allowSRGBInputs, int* nextSampler
Idx); |
129 | 130 |
130 // Helper for generateMipmaps() that ensures mipmaps are up to date | 131 // Helper for generateMipmaps() that ensures mipmaps are up to date |
131 void generateMipmaps(const GrProcessor&, bool allowSRGBInputs); | 132 void generateMipmaps(const GrProcessor&, bool allowSRGBInputs); |
132 | 133 |
(...skipping 10 matching lines...) Expand all Loading... |
143 GrProgramDesc fDesc; | 144 GrProgramDesc fDesc; |
144 GrGLGpu* fGpu; | 145 GrGLGpu* fGpu; |
145 GrGLProgramDataManager fProgramDataManager; | 146 GrGLProgramDataManager fProgramDataManager; |
146 | 147 |
147 friend class GrGLProgramBuilder; | 148 friend class GrGLProgramBuilder; |
148 | 149 |
149 typedef SkRefCnt INHERITED; | 150 typedef SkRefCnt INHERITED; |
150 }; | 151 }; |
151 | 152 |
152 #endif | 153 #endif |
OLD | NEW |