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

Side by Side Diff: src/gpu/GrPipelineBuilder.h

Issue 2114993002: GrFP can express distance vector field req., program builder declares variable for it (Closed) Base URL: https://skia.googlesource.com/skia@dvonbeck-bevel-api-change
Patch Set: Fixed GrPaint unintialized bool Created 4 years, 4 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/GrPipeline.cpp ('k') | src/gpu/GrPipelineBuilder.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 2015 Google Inc. 2 * Copyright 2015 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 GrPipelineBuilder_DEFINED 8 #ifndef GrPipelineBuilder_DEFINED
9 #define GrPipelineBuilder_DEFINED 9 #define GrPipelineBuilder_DEFINED
10 10
(...skipping 203 matching lines...) Expand 10 before | Expand all | Expand 10 after
214 /** 214 /**
215 * Suppress linear -> sRGB conversion when rendering to sRGB render targ ets. 215 * Suppress linear -> sRGB conversion when rendering to sRGB render targ ets.
216 */ 216 */
217 kDisableOutputConversionToSRGB_Flag = 0x04, 217 kDisableOutputConversionToSRGB_Flag = 0x04,
218 218
219 /** 219 /**
220 * Allow sRGB -> linear conversion when reading from sRGB inputs. 220 * Allow sRGB -> linear conversion when reading from sRGB inputs.
221 */ 221 */
222 kAllowSRGBInputs_Flag = 0x08, 222 kAllowSRGBInputs_Flag = 0x08,
223 223
224 kLast_Flag = kAllowSRGBInputs_Flag, 224 /**
225 * Signals that one or more FPs need access to the distance vector field to the nearest
226 * edge
227 */
228 kUsesDistanceVectorField_Flag = 0x10,
229
230 kLast_Flag = kUsesDistanceVectorField_Flag,
225 }; 231 };
226 232
227 bool isHWAntialias() const { return SkToBool(fFlags & kHWAntialias_Flag); } 233 bool isHWAntialias() const { return SkToBool(fFlags & kHWAntialias_Flag); }
228 bool snapVerticesToPixelCenters() const { 234 bool snapVerticesToPixelCenters() const {
229 return SkToBool(fFlags & kSnapVerticesToPixelCenters_Flag); } 235 return SkToBool(fFlags & kSnapVerticesToPixelCenters_Flag); }
230 bool getDisableOutputConversionToSRGB() const { 236 bool getDisableOutputConversionToSRGB() const {
231 return SkToBool(fFlags & kDisableOutputConversionToSRGB_Flag); } 237 return SkToBool(fFlags & kDisableOutputConversionToSRGB_Flag); }
232 bool getAllowSRGBInputs() const { 238 bool getAllowSRGBInputs() const {
233 return SkToBool(fFlags & kAllowSRGBInputs_Flag); } 239 return SkToBool(fFlags & kAllowSRGBInputs_Flag); }
240 bool getUsesDistanceVectorField() const {
241 return SkToBool(fFlags & kUsesDistanceVectorField_Flag); }
234 242
235 /** 243 /**
236 * Enable render state settings. 244 * Enable render state settings.
237 * 245 *
238 * @param flags bitfield of Flags specifying the states to enable 246 * @param flags bitfield of Flags specifying the states to enable
239 */ 247 */
240 void enableState(uint32_t flags) { fFlags |= flags; } 248 void enableState(uint32_t flags) { fFlags |= flags; }
241 249
242 /** 250 /**
243 * Disable render state settings. 251 * Disable render state settings.
(...skipping 56 matching lines...) Expand 10 before | Expand all | Expand 10 after
300 GrDrawFace fDrawFace; 308 GrDrawFace fDrawFace;
301 mutable sk_sp<GrXPFactory> fXPFactory; 309 mutable sk_sp<GrXPFactory> fXPFactory;
302 FragmentProcessorArray fColorFragmentProcessors; 310 FragmentProcessorArray fColorFragmentProcessors;
303 FragmentProcessorArray fCoverageFragmentProcessors; 311 FragmentProcessorArray fCoverageFragmentProcessors;
304 312
305 friend class GrPipeline; 313 friend class GrPipeline;
306 friend class GrDrawTarget; 314 friend class GrDrawTarget;
307 }; 315 };
308 316
309 #endif 317 #endif
OLDNEW
« no previous file with comments | « src/gpu/GrPipeline.cpp ('k') | src/gpu/GrPipelineBuilder.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698