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

Side by Side Diff: src/gpu/glsl/GrGLSLCaps.cpp

Issue 1722363002: Add cap and builder feature for multisample interpolation (Closed) Base URL: https://skia.googlesource.com/skia.git@upload_samplelocations
Patch Set: simplify Created 4 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 | « src/gpu/glsl/GrGLSLCaps.h ('k') | src/gpu/glsl/GrGLSLFragmentShaderBuilder.h » ('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 2012 Google Inc. 2 * Copyright 2012 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 #include "GrGLSLCaps.h" 9 #include "GrGLSLCaps.h"
10 10
11 #include "GrContextOptions.h" 11 #include "GrContextOptions.h"
12 12
13 //////////////////////////////////////////////////////////////////////////////// //////////// 13 //////////////////////////////////////////////////////////////////////////////// ////////////
14 14
15 GrGLSLCaps::GrGLSLCaps(const GrContextOptions& options) { 15 GrGLSLCaps::GrGLSLCaps(const GrContextOptions& options) {
16 fGLSLGeneration = k330_GrGLSLGeneration; 16 fGLSLGeneration = k330_GrGLSLGeneration;
17 17
18 fDropsTileOnZeroDivide = false; 18 fDropsTileOnZeroDivide = false;
19 fFBFetchSupport = false; 19 fFBFetchSupport = false;
20 fFBFetchNeedsCustomOutput = false; 20 fFBFetchNeedsCustomOutput = false;
21 fBindlessTextureSupport = false; 21 fBindlessTextureSupport = false;
22 fUsesPrecisionModifiers = false; 22 fUsesPrecisionModifiers = false;
23 fCanUseAnyFunctionInShader = true; 23 fCanUseAnyFunctionInShader = true;
24 fCanUseMinAndAbsTogether = true; 24 fCanUseMinAndAbsTogether = true;
25 fMustForceNegatedAtanParamToFloat = false; 25 fMustForceNegatedAtanParamToFloat = false;
26 fFlatInterpolationSupport = false; 26 fFlatInterpolationSupport = false;
27 fNoPerspectiveInterpolationSupport = false; 27 fNoPerspectiveInterpolationSupport = false;
28 fMultisampleInterpolationSupport = false;
28 fSampleVariablesSupport = false; 29 fSampleVariablesSupport = false;
29 fSampleMaskOverrideCoverageSupport = false; 30 fSampleMaskOverrideCoverageSupport = false;
30 fVersionDeclString = nullptr; 31 fVersionDeclString = nullptr;
31 fShaderDerivativeExtensionString = nullptr; 32 fShaderDerivativeExtensionString = nullptr;
32 fFragCoordConventionsExtensionString = nullptr; 33 fFragCoordConventionsExtensionString = nullptr;
33 fSecondaryOutputExtensionString = nullptr; 34 fSecondaryOutputExtensionString = nullptr;
34 fExternalTextureExtensionString = nullptr; 35 fExternalTextureExtensionString = nullptr;
35 fNoPerspectiveInterpolationExtensionString = nullptr; 36 fNoPerspectiveInterpolationExtensionString = nullptr;
37 fMultisampleInterpolationExtensionString = nullptr;
36 fSampleVariablesExtensionString = nullptr; 38 fSampleVariablesExtensionString = nullptr;
37 fFBFetchColorName = nullptr; 39 fFBFetchColorName = nullptr;
38 fFBFetchExtensionString = nullptr; 40 fFBFetchExtensionString = nullptr;
39 fAdvBlendEqInteraction = kNotSupported_AdvBlendEqInteraction; 41 fAdvBlendEqInteraction = kNotSupported_AdvBlendEqInteraction;
40 } 42 }
41 43
42 SkString GrGLSLCaps::dump() const { 44 SkString GrGLSLCaps::dump() const {
43 SkString r = INHERITED::dump(); 45 SkString r = INHERITED::dump();
44 46
45 static const char* kAdvBlendEqInteractionStr[] = { 47 static const char* kAdvBlendEqInteractionStr[] = {
(...skipping 14 matching lines...) Expand all
60 r.appendf("Drops tile on zero divide: %s\n", (fDropsTileOnZeroDivide ? "YES" : "NO")); 62 r.appendf("Drops tile on zero divide: %s\n", (fDropsTileOnZeroDivide ? "YES" : "NO"));
61 r.appendf("Bindless texture support: %s\n", (fBindlessTextureSupport ? "YES" : "NO")); 63 r.appendf("Bindless texture support: %s\n", (fBindlessTextureSupport ? "YES" : "NO"));
62 r.appendf("Uses precision modifiers: %s\n", (fUsesPrecisionModifiers ? "YES" : "NO")); 64 r.appendf("Uses precision modifiers: %s\n", (fUsesPrecisionModifiers ? "YES" : "NO"));
63 r.appendf("Can use any() function: %s\n", (fCanUseAnyFunctionInShader ? "YES " : "NO")); 65 r.appendf("Can use any() function: %s\n", (fCanUseAnyFunctionInShader ? "YES " : "NO"));
64 r.appendf("Can use min() and abs() together: %s\n", (fCanUseMinAndAbsTogethe r ? "YES" : "NO")); 66 r.appendf("Can use min() and abs() together: %s\n", (fCanUseMinAndAbsTogethe r ? "YES" : "NO"));
65 r.appendf("Must force negated atan param to float: %s\n", (fMustForceNegated AtanParamToFloat ? 67 r.appendf("Must force negated atan param to float: %s\n", (fMustForceNegated AtanParamToFloat ?
66 "YES" : "NO")); 68 "YES" : "NO"));
67 r.appendf("Flat interpolation support: %s\n", (fFlatInterpolationSupport ? "YES" : "NO")); 69 r.appendf("Flat interpolation support: %s\n", (fFlatInterpolationSupport ? "YES" : "NO"));
68 r.appendf("No perspective interpolation support: %s\n", (fNoPerspectiveInter polationSupport ? 70 r.appendf("No perspective interpolation support: %s\n", (fNoPerspectiveInter polationSupport ?
69 "YES" : "NO")); 71 "YES" : "NO"));
72 r.appendf("Multisample interpolation support: %s\n", (fMultisampleInterpolat ionSupport ?
joshualitt 2016/03/01 17:58:58 Should we log the string? we don't do it for fb fe
bsalomon 2016/03/01 18:02:26 Seems like it'd be nice to log both.
joshualitt 2016/03/01 18:02:45 whoops, should have paid more attention, the strin
73 "YES" : "NO"));
70 r.appendf("Sample variables support: %s\n", (fSampleVariablesSupport ? "YES" : "NO")); 74 r.appendf("Sample variables support: %s\n", (fSampleVariablesSupport ? "YES" : "NO"));
71 r.appendf("Sample mask override coverage support: %s\n", (fSampleMaskOverrid eCoverageSupport ? 75 r.appendf("Sample mask override coverage support: %s\n", (fSampleMaskOverrid eCoverageSupport ?
72 "YES" : "NO")); 76 "YES" : "NO"));
73 r.appendf("Advanced blend equation interaction: %s\n", 77 r.appendf("Advanced blend equation interaction: %s\n",
74 kAdvBlendEqInteractionStr[fAdvBlendEqInteraction]); 78 kAdvBlendEqInteractionStr[fAdvBlendEqInteraction]);
75 return r; 79 return r;
76 } 80 }
77 81
78 void GrGLSLCaps::onApplyOptionsOverrides(const GrContextOptions& options) { 82 void GrGLSLCaps::onApplyOptionsOverrides(const GrContextOptions& options) {
79 } 83 }
80 84
OLDNEW
« no previous file with comments | « src/gpu/glsl/GrGLSLCaps.h ('k') | src/gpu/glsl/GrGLSLFragmentShaderBuilder.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698