[Webkit-unassigned] [Bug 214948] REGRESSION: [ ios14 ] webgl/1.0.3/conformance/glsl/functions/glsl-function-sign.html and webgl/1.0.3/conformance/glsl/misc/glsl-function-nodes.html are failing consistently.

bugzilla-daemon at webkit.org bugzilla-daemon at webkit.org
Wed Jul 29 17:48:48 PDT 2020


https://bugs.webkit.org/show_bug.cgi?id=214948

--- Comment #7 from Dean Jackson <dino at apple.com> ---
Let's try to work out what it is actually returning!

texcoord is the normalized vertex position.

vec4 color = vec4(
       texcoord,
       texcoord.x * texcoord.y,
       (1.0 - texcoord.x) * texcoord.y * 0.5 + 0.5);

So for input texcoords...

0,0 -> color = 0, 0, 0, 0.5
0,1 -> color = 0, 1, 0, 1
1,0 -> color = 1, 0, 0, 1
1,1 -> color = 1, 1, 1, 0.5

Now the varying value

vColor = vec4(
    sign(color.x * 2.0 - 1.0) * 0.5 + 0.5,
    0.5,
    0,
    1);

0,0 [[sign(-1) * 0.5 + 0.5]] -> 0, 0.5, 0, 1
0,1 [[sign(-1) * 0.5 + 0.5]] -> 0, 0.5, 0, 1
1,0 [[sign(1) * 0.5 + 0.5]]  -> 1, 0.5, 0, 1
1,1 [[sign(1) * 0.5 + 0.5]]  -> 1, 0.5, 0, 1

Attaching the result as a screenshot.

-- 
You are receiving this mail because:
You are the assignee for the bug.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.webkit.org/pipermail/webkit-unassigned/attachments/20200730/463506c8/attachment.htm>


More information about the webkit-unassigned mailing list