skia2/tests/sksl/workarounds
Brian Salomon d8d85b9b89 Reland "Don't key progams/pipelines on origin.""
Reland works around Adreno issue with this formulation of sk_Clockwise:
 (sk_RTFlip.y < 0.0 ? !gl_FrontFacing : gl_FrontFacing)

and instead adds this to the top of the function:
 bool sk_Clockwise = gl_FrontFacing;
 if (sk_RTFlip.y < 0.0) {
      sk_Clockwise = !sk_Clockwise;
 }

Original description:

SkSL language features that are origin sensitive now use a uniform
to conditionally flip their result rather than generating different
code.

Previously we would insert a "rt height" uniform if sk_FragCoord needed
to be flipped. sk_FragCoord,y was implemented as "realFragCoord.y" or
"rtHeight - realFragCoord.y" depending on SkSL::ProgramSettings::fFlipY.

Now we instead use a two component vector rtFlip and sk_FragCoord.y is
always "rtFlip.x + rtFlip.y*realFragCoord.y". We configure rtFlip as
either (0, 1) or (rtHeight, -1). sk_Clockwise and dFdy simiarly use
rtFlip.y to emit code that always works with either origin.

Bug: skia:12037
Change-Id: I3a2ad6f5667eb4dcd823b939abd5698f89b58929
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/425178
Reviewed-by: Ethan Nicholas <ethannicholas@google.com>
Commit-Queue: Brian Salomon <bsalomon@google.com>
2021-07-07 14:50:10 +00:00
..
AbsInt.glsl Migrate SkSL test inputs to the resources/ directory. 2021-01-22 18:57:29 +00:00
AbsIntStandaloneSettings.glsl Migrate SkSL test inputs to the resources/ directory. 2021-01-22 18:57:29 +00:00
BlendGuardedDivide.glsl Mangle function names in GLSL. 2021-03-22 17:18:26 +00:00
BlendGuardedDivideStandaloneSettings.glsl Mangle function names in GLSL. 2021-03-22 17:18:26 +00:00
BlendModesAllZeroVec.glsl Remove extraneous line-breaks in generated GLSL/Metal code. 2021-03-12 18:39:57 +00:00
BlendModesAllZeroVecStandaloneSettings.glsl Remove extraneous line-breaks in generated GLSL/Metal code. 2021-03-12 18:39:57 +00:00
FractNegative.glsl Performance experiment: disable control-flow analysis. 2021-03-08 19:41:19 +00:00
FractNegativeStandaloneSettings.glsl Performance experiment: disable control-flow analysis. 2021-03-08 19:41:19 +00:00
FragCoords.glsl Migrate SkSL test inputs to the resources/ directory. 2021-01-22 18:57:29 +00:00
FragCoordsStandaloneSettings.glsl Reland "Don't key progams/pipelines on origin."" 2021-07-07 14:50:10 +00:00
LoopCondition.glsl Migrate SkSL test inputs to the resources/ directory. 2021-01-22 18:57:29 +00:00
LoopConditionStandaloneSettings.glsl Migrate SkSL test inputs to the resources/ directory. 2021-01-22 18:57:29 +00:00
MinAndAbsTogether.glsl Performance experiment: disable control-flow analysis. 2021-03-08 19:41:19 +00:00
MinAndAbsTogetherStandaloneSettings.glsl Performance experiment: disable control-flow analysis. 2021-03-08 19:41:19 +00:00
NegatedAtan.glsl Remove usage of sqrt() as an optimization barrier in tests. 2021-05-24 17:18:54 +00:00
NegatedAtanStandaloneSettings.glsl Remove usage of sqrt() as an optimization barrier in tests. 2021-05-24 17:18:54 +00:00
NegatedLdexp.glsl Add a workaround for "ldexp(..., -x)" on Mac/Radeon/GLSL 2021-06-08 01:39:38 +00:00
NegatedLdexpStandaloneSettings.glsl Add a workaround for "ldexp(..., -x)" on Mac/Radeon/GLSL 2021-06-08 01:39:38 +00:00
PowWithConstantExponent.glsl Migrate SkSL test inputs to the resources/ directory. 2021-01-22 18:57:29 +00:00
PowWithConstantExponentStandaloneSettings.glsl Migrate SkSL test inputs to the resources/ directory. 2021-01-22 18:57:29 +00:00
RewriteDoWhileLoops.glsl Migrate SkSL test inputs to the resources/ directory. 2021-01-22 18:57:29 +00:00
RewriteDoWhileLoopsStandaloneSettings.glsl Migrate SkSL test inputs to the resources/ directory. 2021-01-22 18:57:29 +00:00
RewriteMatrixComparisons.glsl Rewrite matrix comparisons to work around Adreno bug. 2021-05-24 13:42:19 +00:00
RewriteMatrixComparisonsStandaloneSettings.glsl Rename caps bit for matrix comparison rewrites. 2021-05-21 22:31:53 +00:00
RewriteMatrixVectorMultiply.asm.frag Rewrite matrix * vector multiplication on ARM GPUs. 2021-03-24 19:21:44 +00:00
RewriteMatrixVectorMultiply.glsl Rewrite matrix * vector multiplication on ARM GPUs. 2021-03-24 19:21:44 +00:00
RewriteMatrixVectorMultiplyStandaloneSettings.glsl Add caps bit for RewriteMatrixVectorMultiply. 2021-03-23 22:40:02 +00:00
TernaryShortCircuit.glsl Migrate SkSL test inputs to the resources/ directory. 2021-01-22 18:57:29 +00:00
TernaryShortCircuitStandaloneSettings.glsl Migrate SkSL test inputs to the resources/ directory. 2021-01-22 18:57:29 +00:00