Clamp GrSkSLFP output to valid premul
Added this as an option to GrSaturateProcessor (also renamed it to
be more generic and end with FragmentProcessor).
Added a tweak to the unit test to check the new behavior.
(Raster was already doing the clamp).
Change-Id: Ic49fa5cd72b6c63430fb773baf8121546bf2b80d
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/265580
Reviewed-by: Brian Salomon <bsalomon@google.com>
Commit-Queue: Brian Osman <brianosman@google.com>
diff --git a/gn/sksl.gni b/gn/sksl.gni
index 34b616e..acc3242 100644
--- a/gn/sksl.gni
+++ b/gn/sksl.gni
@@ -41,6 +41,7 @@
"$_src/gpu/effects/GrBlurredEdgeFragmentProcessor.fp",
"$_src/gpu/effects/GrCircleBlurFragmentProcessor.fp",
"$_src/gpu/effects/GrCircleEffect.fp",
+ "$_src/gpu/effects/GrClampFragmentProcessor.fp",
"$_src/gpu/effects/GrComposeLerpEffect.fp",
"$_src/gpu/effects/GrComposeLerpRedEffect.fp",
"$_src/gpu/effects/GrConfigConversionEffect.fp",
@@ -56,7 +57,6 @@
"$_src/gpu/effects/GrRectBlurEffect.fp",
"$_src/gpu/effects/GrRGBToHSLFilterEffect.fp",
"$_src/gpu/effects/GrRRectBlurEffect.fp",
- "$_src/gpu/effects/GrSaturateProcessor.fp",
"$_src/gpu/gradients/GrDualIntervalGradientColorizer.fp",
"$_src/gpu/gradients/GrSingleIntervalGradientColorizer.fp",
"$_src/gpu/gradients/GrTextureGradientColorizer.fp",