Flutter Engine
The Flutter Engine
Static Public Member Functions | List of all members
ShaderCapsTestFactory Class Reference
Inheritance diagram for ShaderCapsTestFactory:
SkSL::ShaderCapsFactory

Static Public Member Functions

static const SkSL::ShaderCapsAddAndTrueToLoopCondition ()
 
static const SkSL::ShaderCapsCannotUseFractForNegativeValues ()
 
static const SkSL::ShaderCapsCannotUseFragCoord ()
 
static const SkSL::ShaderCapsCannotUseMinAndAbsTogether ()
 
static const SkSL::ShaderCapsCannotUseVoidInSequenceExpressions ()
 
static const SkSL::ShaderCapsDualSourceBlending ()
 
static const SkSL::ShaderCapsEmulateAbsIntFunction ()
 
static const SkSL::ShaderCapsFramebufferFetchSupport ()
 
static const SkSL::ShaderCapsMustDeclareFragmentFrontFacing ()
 
static const SkSL::ShaderCapsMustForceNegatedAtanParamToFloat ()
 
static const SkSL::ShaderCapsMustForceNegatedLdexpParamToMultiply ()
 
static const SkSL::ShaderCapsMustGuardDivisionEvenAfterExplicitZeroCheck ()
 
static const SkSL::ShaderCapsNoBuiltinDeterminantSupport ()
 
static const SkSL::ShaderCapsNoBuiltinFMASupport ()
 
static const SkSL::ShaderCapsNoExternalTextureSupport ()
 
static const SkSL::ShaderCapsRemovePowWithConstantExponent ()
 
static const SkSL::ShaderCapsRewriteDoWhileLoops ()
 
static const SkSL::ShaderCapsRewriteMatrixComparisons ()
 
static const SkSL::ShaderCapsRewriteMatrixVectorMultiply ()
 
static const SkSL::ShaderCapsRewriteSwitchStatements ()
 
static const SkSL::ShaderCapsSampleMaskSupport ()
 
static const SkSL::ShaderCapsShaderDerivativeExtensionString ()
 
static const SkSL::ShaderCapsUnfoldShortCircuitAsTernary ()
 
static const SkSL::ShaderCapsUsesPrecisionModifiers ()
 
static const SkSL::ShaderCapsVersion110 ()
 
static const SkSL::ShaderCapsVersion450Core ()
 
- Static Public Member Functions inherited from SkSL::ShaderCapsFactory
static const ShaderCapsDefault ()
 
static const ShaderCapsStandalone ()
 

Additional Inherited Members

- Static Protected Member Functions inherited from SkSL::ShaderCapsFactory
static std::unique_ptr< ShaderCapsMakeShaderCaps ()
 

Detailed Description

Definition at line 79 of file Main.cpp.

Member Function Documentation

◆ AddAndTrueToLoopCondition()

static const SkSL::ShaderCaps * ShaderCapsTestFactory::AddAndTrueToLoopCondition ( )
inlinestatic

Definition at line 81 of file Main.cpp.

81 {
82 static const SkSL::ShaderCaps* sCaps = []{
83 std::unique_ptr<SkSL::ShaderCaps> caps = MakeShaderCaps();
84 caps->fVersionDeclString = "#version 400";
85 caps->fAddAndTrueToLoopCondition = true;
86 return caps.release();
87 }();
88 return sCaps;
89 }
static std::unique_ptr< ShaderCaps > MakeShaderCaps()
Definition: SkSLUtil.cpp:25

◆ CannotUseFractForNegativeValues()

static const SkSL::ShaderCaps * ShaderCapsTestFactory::CannotUseFractForNegativeValues ( )
inlinestatic

Definition at line 91 of file Main.cpp.

91 {
92 static const SkSL::ShaderCaps* sCaps = [] {
93 std::unique_ptr<SkSL::ShaderCaps> caps = MakeShaderCaps();
94 caps->fVersionDeclString = "#version 400";
95 caps->fCanUseFractForNegativeValues = false;
96 return caps.release();
97 }();
98 return sCaps;
99 }

◆ CannotUseFragCoord()

static const SkSL::ShaderCaps * ShaderCapsTestFactory::CannotUseFragCoord ( )
inlinestatic

Definition at line 101 of file Main.cpp.

101 {
102 static const SkSL::ShaderCaps* sCaps = [] {
103 std::unique_ptr<SkSL::ShaderCaps> caps = MakeShaderCaps();
104 caps->fVersionDeclString = "#version 400";
105 caps->fCanUseFragCoord = false;
106 return caps.release();
107 }();
108 return sCaps;
109 }

◆ CannotUseMinAndAbsTogether()

static const SkSL::ShaderCaps * ShaderCapsTestFactory::CannotUseMinAndAbsTogether ( )
inlinestatic

Definition at line 111 of file Main.cpp.

111 {
112 static const SkSL::ShaderCaps* sCaps = [] {
113 std::unique_ptr<SkSL::ShaderCaps> caps = MakeShaderCaps();
114 caps->fVersionDeclString = "#version 400";
115 caps->fCanUseMinAndAbsTogether = false;
116 return caps.release();
117 }();
118 return sCaps;
119 }

◆ CannotUseVoidInSequenceExpressions()

static const SkSL::ShaderCaps * ShaderCapsTestFactory::CannotUseVoidInSequenceExpressions ( )
inlinestatic

Definition at line 121 of file Main.cpp.

121 {
122 static const SkSL::ShaderCaps* sCaps = [] {
123 std::unique_ptr<SkSL::ShaderCaps> caps = MakeShaderCaps();
124 caps->fCanUseVoidInSequenceExpressions = false;
125 return caps.release();
126 }();
127 return sCaps;
128 }

◆ DualSourceBlending()

static const SkSL::ShaderCaps * ShaderCapsTestFactory::DualSourceBlending ( )
inlinestatic

Definition at line 131 of file Main.cpp.

131 {
132 static const SkSL::ShaderCaps* sCaps = [] {
133 std::unique_ptr<SkSL::ShaderCaps> caps = MakeShaderCaps();
134 caps->fDualSourceBlendingSupport = true;
135 return caps.release();
136 }();
137 return sCaps;
138 }

◆ EmulateAbsIntFunction()

static const SkSL::ShaderCaps * ShaderCapsTestFactory::EmulateAbsIntFunction ( )
inlinestatic

Definition at line 140 of file Main.cpp.

140 {
141 static const SkSL::ShaderCaps* sCaps = [] {
142 std::unique_ptr<SkSL::ShaderCaps> caps = MakeShaderCaps();
143 caps->fVersionDeclString = "#version 400";
144 caps->fEmulateAbsIntFunction = true;
145 return caps.release();
146 }();
147 return sCaps;
148 }

◆ FramebufferFetchSupport()

static const SkSL::ShaderCaps * ShaderCapsTestFactory::FramebufferFetchSupport ( )
inlinestatic

Definition at line 150 of file Main.cpp.

150 {
151 static const SkSL::ShaderCaps* sCaps = [] {
152 std::unique_ptr<SkSL::ShaderCaps> caps = MakeShaderCaps();
153 caps->fFBFetchSupport = true;
154 caps->fFBFetchColorName = "FramebufferFragColor"; // a nice, backend-neutral name
155 return caps.release();
156 }();
157 return sCaps;
158 }

◆ MustDeclareFragmentFrontFacing()

static const SkSL::ShaderCaps * ShaderCapsTestFactory::MustDeclareFragmentFrontFacing ( )
inlinestatic

Definition at line 160 of file Main.cpp.

160 {
161 static const SkSL::ShaderCaps* sCaps = [] {
162 std::unique_ptr<SkSL::ShaderCaps> caps = MakeShaderCaps();
163 caps->fMustDeclareFragmentFrontFacing = true;
164 return caps.release();
165 }();
166 return sCaps;
167 }

◆ MustForceNegatedAtanParamToFloat()

static const SkSL::ShaderCaps * ShaderCapsTestFactory::MustForceNegatedAtanParamToFloat ( )
inlinestatic

Definition at line 169 of file Main.cpp.

169 {
170 static const SkSL::ShaderCaps* sCaps = [] {
171 std::unique_ptr<SkSL::ShaderCaps> caps = MakeShaderCaps();
172 caps->fVersionDeclString = "#version 400";
173 caps->fMustForceNegatedAtanParamToFloat = true;
174 return caps.release();
175 }();
176 return sCaps;
177 }

◆ MustForceNegatedLdexpParamToMultiply()

static const SkSL::ShaderCaps * ShaderCapsTestFactory::MustForceNegatedLdexpParamToMultiply ( )
inlinestatic

Definition at line 179 of file Main.cpp.

179 {
180 static const SkSL::ShaderCaps* sCaps = [] {
181 std::unique_ptr<SkSL::ShaderCaps> caps = MakeShaderCaps();
182 caps->fVersionDeclString = "#version 400";
183 caps->fMustForceNegatedLdexpParamToMultiply = true;
184 return caps.release();
185 }();
186 return sCaps;
187 }

◆ MustGuardDivisionEvenAfterExplicitZeroCheck()

static const SkSL::ShaderCaps * ShaderCapsTestFactory::MustGuardDivisionEvenAfterExplicitZeroCheck ( )
inlinestatic

Definition at line 189 of file Main.cpp.

189 {
190 static const SkSL::ShaderCaps* sCaps = [] {
191 std::unique_ptr<SkSL::ShaderCaps> caps = MakeShaderCaps();
192 caps->fMustGuardDivisionEvenAfterExplicitZeroCheck = true;
193 return caps.release();
194 }();
195 return sCaps;
196 }

◆ NoBuiltinDeterminantSupport()

static const SkSL::ShaderCaps * ShaderCapsTestFactory::NoBuiltinDeterminantSupport ( )
inlinestatic

Definition at line 198 of file Main.cpp.

198 {
199 static const SkSL::ShaderCaps* sCaps = [] {
200 std::unique_ptr<SkSL::ShaderCaps> caps = MakeShaderCaps();
201 caps->fVersionDeclString = "#version 400";
202 caps->fBuiltinDeterminantSupport = false;
203 return caps.release();
204 }();
205 return sCaps;
206 }

◆ NoBuiltinFMASupport()

static const SkSL::ShaderCaps * ShaderCapsTestFactory::NoBuiltinFMASupport ( )
inlinestatic

Definition at line 208 of file Main.cpp.

208 {
209 static const SkSL::ShaderCaps* sCaps = [] {
210 std::unique_ptr<SkSL::ShaderCaps> caps = MakeShaderCaps();
211 caps->fVersionDeclString = "#version 400";
212 caps->fBuiltinFMASupport = false;
213 return caps.release();
214 }();
215 return sCaps;
216 }

◆ NoExternalTextureSupport()

static const SkSL::ShaderCaps * ShaderCapsTestFactory::NoExternalTextureSupport ( )
inlinestatic

Definition at line 218 of file Main.cpp.

218 {
219 static const SkSL::ShaderCaps* sCaps = [] {
220 std::unique_ptr<SkSL::ShaderCaps> caps = MakeShaderCaps();
221 caps->fVersionDeclString = "#version 400";
222 caps->fExternalTextureSupport = false;
223 return caps.release();
224 }();
225 return sCaps;
226 }

◆ RemovePowWithConstantExponent()

static const SkSL::ShaderCaps * ShaderCapsTestFactory::RemovePowWithConstantExponent ( )
inlinestatic

Definition at line 228 of file Main.cpp.

228 {
229 static const SkSL::ShaderCaps* sCaps = [] {
230 std::unique_ptr<SkSL::ShaderCaps> caps = MakeShaderCaps();
231 caps->fVersionDeclString = "#version 400";
232 caps->fRemovePowWithConstantExponent = true;
233 return caps.release();
234 }();
235 return sCaps;
236 }

◆ RewriteDoWhileLoops()

static const SkSL::ShaderCaps * ShaderCapsTestFactory::RewriteDoWhileLoops ( )
inlinestatic

Definition at line 238 of file Main.cpp.

238 {
239 static const SkSL::ShaderCaps* sCaps = [] {
240 std::unique_ptr<SkSL::ShaderCaps> caps = MakeShaderCaps();
241 caps->fVersionDeclString = "#version 400";
242 caps->fRewriteDoWhileLoops = true;
243 return caps.release();
244 }();
245 return sCaps;
246 }

◆ RewriteMatrixComparisons()

static const SkSL::ShaderCaps * ShaderCapsTestFactory::RewriteMatrixComparisons ( )
inlinestatic

Definition at line 248 of file Main.cpp.

248 {
249 static const SkSL::ShaderCaps* sCaps = [] {
250 std::unique_ptr<SkSL::ShaderCaps> caps = MakeShaderCaps();
251 caps->fRewriteMatrixComparisons = true;
252 caps->fUsesPrecisionModifiers = true;
253 return caps.release();
254 }();
255 return sCaps;
256 }

◆ RewriteMatrixVectorMultiply()

static const SkSL::ShaderCaps * ShaderCapsTestFactory::RewriteMatrixVectorMultiply ( )
inlinestatic

Definition at line 258 of file Main.cpp.

258 {
259 static const SkSL::ShaderCaps* sCaps = [] {
260 std::unique_ptr<SkSL::ShaderCaps> caps = MakeShaderCaps();
261 caps->fVersionDeclString = "#version 400";
262 caps->fRewriteMatrixVectorMultiply = true;
263 return caps.release();
264 }();
265 return sCaps;
266 }

◆ RewriteSwitchStatements()

static const SkSL::ShaderCaps * ShaderCapsTestFactory::RewriteSwitchStatements ( )
inlinestatic

Definition at line 268 of file Main.cpp.

268 {
269 static const SkSL::ShaderCaps* sCaps = [] {
270 std::unique_ptr<SkSL::ShaderCaps> caps = MakeShaderCaps();
271 caps->fVersionDeclString = "#version 400";
272 caps->fRewriteSwitchStatements = true;
273 return caps.release();
274 }();
275 return sCaps;
276 }

◆ SampleMaskSupport()

static const SkSL::ShaderCaps * ShaderCapsTestFactory::SampleMaskSupport ( )
inlinestatic

Definition at line 278 of file Main.cpp.

278 {
279 static const SkSL::ShaderCaps* sCaps = [] {
280 std::unique_ptr<SkSL::ShaderCaps> caps = MakeShaderCaps();
281 caps->fVersionDeclString = "#version 400";
282 caps->fShaderDerivativeSupport = true;
283 caps->fSampleMaskSupport = true;
284 return caps.release();
285 }();
286 return sCaps;
287 }

◆ ShaderDerivativeExtensionString()

static const SkSL::ShaderCaps * ShaderCapsTestFactory::ShaderDerivativeExtensionString ( )
inlinestatic

Definition at line 289 of file Main.cpp.

289 {
290 static const SkSL::ShaderCaps* sCaps = [] {
291 std::unique_ptr<SkSL::ShaderCaps> caps = MakeShaderCaps();
292 caps->fVersionDeclString = "#version 400";
293 caps->fShaderDerivativeSupport = true;
294 caps->fShaderDerivativeExtensionString = "GL_OES_standard_derivatives";
295 caps->fUsesPrecisionModifiers = true;
296 return caps.release();
297 }();
298 return sCaps;
299 }

◆ UnfoldShortCircuitAsTernary()

static const SkSL::ShaderCaps * ShaderCapsTestFactory::UnfoldShortCircuitAsTernary ( )
inlinestatic

Definition at line 301 of file Main.cpp.

301 {
302 static const SkSL::ShaderCaps* sCaps = [] {
303 std::unique_ptr<SkSL::ShaderCaps> caps = MakeShaderCaps();
304 caps->fVersionDeclString = "#version 400";
305 caps->fUnfoldShortCircuitAsTernary = true;
306 return caps.release();
307 }();
308 return sCaps;
309 }

◆ UsesPrecisionModifiers()

static const SkSL::ShaderCaps * ShaderCapsTestFactory::UsesPrecisionModifiers ( )
inlinestatic

Definition at line 311 of file Main.cpp.

311 {
312 static const SkSL::ShaderCaps* sCaps = [] {
313 std::unique_ptr<SkSL::ShaderCaps> caps = MakeShaderCaps();
314 caps->fVersionDeclString = "#version 400";
315 caps->fUsesPrecisionModifiers = true;
316 return caps.release();
317 }();
318 return sCaps;
319 }

◆ Version110()

static const SkSL::ShaderCaps * ShaderCapsTestFactory::Version110 ( )
inlinestatic

Definition at line 321 of file Main.cpp.

321 {
322 static const SkSL::ShaderCaps* sCaps = [] {
323 std::unique_ptr<SkSL::ShaderCaps> caps = MakeShaderCaps();
324 caps->fVersionDeclString = "#version 110";
325 caps->fGLSLGeneration = SkSL::GLSLGeneration::k110;
326 return caps.release();
327 }();
328 return sCaps;
329 }

◆ Version450Core()

static const SkSL::ShaderCaps * ShaderCapsTestFactory::Version450Core ( )
inlinestatic

Definition at line 331 of file Main.cpp.

331 {
332 static const SkSL::ShaderCaps* sCaps = [] {
333 std::unique_ptr<SkSL::ShaderCaps> caps = MakeShaderCaps();
334 caps->fVersionDeclString = "#version 450 core";
335 return caps.release();
336 }();
337 return sCaps;
338 }

The documentation for this class was generated from the following file: