diff options
author | 2017-08-17 11:07:59 -0400 | |
---|---|---|
committer | 2017-08-17 15:08:17 +0000 | |
commit | 1d816b92bb7cf2258007f3f74ffd143b89f25d01 (patch) | |
tree | 07fb1e8e2631208eb007a4abdfe130db91e6cfc2 /src/effects/GrCircleBlurFragmentProcessor.fp | |
parent | 23f92277b916a4bdf11c320799ac9248af60a62e (diff) |
Revert "Switched highp float to highfloat and mediump float to half."
This reverts commit 88d99c63878c2d3d340120f0321676f72afcb4f0.
Reason for revert: Believed to be causing unit test failures in Chrome roll:
https://build.chromium.org/p/tryserver.chromium.android/builders/linux_android_rel_ng/builds/364433
https://luci-logdog.appspot.com/v/?s=chromium%2Fbb%2Ftryserver.chromium.android%2Flinux_android_rel_ng%2F364433%2F%2B%2Frecipes%2Fsteps%2Fcontent_browsertests__with_patch__on_Android%2F0%2Flogs%2FWebRtcCaptureFromElementBrowserTest.VerifyCanvasWebGLCaptureColor%2F0
Original change's description:
> Switched highp float to highfloat and mediump float to half.
>
> The ultimate goal is to end up with "float" and "half", but this
> intermediate step uses "highfloat" so that it is clear if I missed a
> "float" somewhere. Once this lands, a subsequent CL will switch all
> "highfloats" back to "floats".
>
> Bug: skia:
> Change-Id: Ia13225c7a0a0a2901e07665891c473d2500ddcca
> Reviewed-on: https://skia-review.googlesource.com/31000
> Commit-Queue: Ethan Nicholas <ethannicholas@google.com>
> Reviewed-by: Brian Salomon <bsalomon@google.com>
TBR=bsalomon@google.com,csmartdalton@google.com,ethannicholas@google.com
Change-Id: I8bfa97547ac3920d433665f161d27df3f15c83aa
No-Presubmit: true
No-Tree-Checks: true
No-Try: true
Bug: skia:
Reviewed-on: https://skia-review.googlesource.com/35705
Commit-Queue: Brian Salomon <bsalomon@google.com>
Reviewed-by: Brian Salomon <bsalomon@google.com>
Diffstat (limited to 'src/effects/GrCircleBlurFragmentProcessor.fp')
-rw-r--r-- | src/effects/GrCircleBlurFragmentProcessor.fp | 16 |
1 files changed, 8 insertions, 8 deletions
diff --git a/src/effects/GrCircleBlurFragmentProcessor.fp b/src/effects/GrCircleBlurFragmentProcessor.fp index d91bad8440..856a468b6c 100644 --- a/src/effects/GrCircleBlurFragmentProcessor.fp +++ b/src/effects/GrCircleBlurFragmentProcessor.fp @@ -1,13 +1,13 @@ -in half4 circleRect; -in half textureRadius; -in half solidRadius; +in float4 circleRect; +in float textureRadius; +in float solidRadius; in uniform sampler2D blurProfileSampler; // The data is formatted as: // x, y - the center of the circle // z - inner radius that should map to 0th entry in the texture. // w - the inverse of the distance over which the texture is stretched. -uniform half4 circleData; +uniform float4 circleData; @optimizationFlags { kCompatibleWithCoverageAsAlpha_OptimizationFlag @@ -273,10 +273,10 @@ uniform half4 circleData; void main() { // We just want to compute "(length(vec) - circleData.z + 0.5) * circleData.w" but need to // rearrange for precision. - half2 vec = half2((sk_FragCoord.x - circleData.x) * circleData.w, - (sk_FragCoord.y - circleData.y) * circleData.w); - half dist = length(vec) + (0.5 - circleData.z) * circleData.w; - sk_OutColor = sk_InColor * texture(blurProfileSampler, half2(dist, 0.5)).a; + float2 vec = float2((sk_FragCoord.x - circleData.x) * circleData.w, + (sk_FragCoord.y - circleData.y) * circleData.w); + float dist = length(vec) + (0.5 - circleData.z) * circleData.w; + sk_OutColor = sk_InColor * texture(blurProfileSampler, float2(dist, 0.5)).a; } @test(testData) { |