SkSL is now pickier about type conversions

Bug: skia:
Change-Id: I4e8b8f229f4e4344f160b0dbb41832764d0b75bd
Reviewed-on: https://skia-review.googlesource.com/c/188311
Commit-Queue: Ethan Nicholas <ethannicholas@google.com>
Reviewed-by: Brian Salomon <bsalomon@google.com>
diff --git a/src/gpu/effects/GrConfigConversionEffect.cpp b/src/gpu/effects/GrConfigConversionEffect.cpp
index 6493fcb..158ff90 100644
--- a/src/gpu/effects/GrConfigConversionEffect.cpp
+++ b/src/gpu/effects/GrConfigConversionEffect.cpp
@@ -27,11 +27,10 @@
 
         fragBuilder->forceHighPrecision();
         fragBuilder->codeAppendf(
-                "%s = half4(floor(float4(float4(%s * 255.0) + 0.5)) / 255.0);\n@switch (%d) {\n    "
-                "case 0:\n        %s.xyz = half3(floor(float3(float3((%s.xyz * %s.w) * 255.0) + "
-                "0.5)) / 255.0);\n        break;\n    case 1:\n        %s.xyz = float(%s.w) <= 0.0 "
-                "? half3(0.0) : half3(floor(float3(float3((%s.xyz / %s.w) * 255.0) + 0.5)) / "
-                "255.0);\n        break;\n}\n",
+                "%s = floor(%s * 255.0 + 0.5) / 255.0;\n@switch (%d) {\n    case 0:\n        "
+                "%s.xyz = floor((%s.xyz * %s.w) * 255.0 + 0.5) / 255.0;\n        break;\n    case "
+                "1:\n        %s.xyz = %s.w <= 0.0 ? half3(0.0) : floor((%s.xyz / %s.w) * 255.0 + "
+                "0.5) / 255.0;\n        break;\n}\n",
                 args.fOutputColor, args.fInputColor, (int)_outer.pmConversion(), args.fOutputColor,
                 args.fOutputColor, args.fOutputColor, args.fOutputColor, args.fOutputColor,
                 args.fOutputColor, args.fOutputColor);