[Webkit-unassigned] [Bug 171359] New: Uniform count in one WebGL shader program prevents unrelated shader program from drawing

bugzilla-daemon at webkit.org bugzilla-daemon at webkit.org
Wed Apr 26 17:49:26 PDT 2017


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

            Bug ID: 171359
           Summary: Uniform count in one WebGL shader program prevents
                    unrelated shader program from drawing
           Product: WebKit
           Version: Safari 10
          Hardware: All
                OS: All
            Status: NEW
          Severity: Normal
          Priority: P2
         Component: WebGL
          Assignee: webkit-unassigned at lists.webkit.org
          Reporter: ajf at ajf.me
                CC: dino at apple.com

Created attachment 308315

  --> https://bugs.webkit.org/attachment.cgi?id=308315&action=review

The test case

The test case (attached: minimal.html) is a small WebGL application. It has two shader programs with their own vertex and fragment shaders. It uses drawArrays with one piece of geometry and the first shader program, then uses drawArrays with another piece of geometry and the other shader program.

In Firefox and Chrome (on macOS), and Microsoft Edge (on Windows 10), both draws succeed. You see a black field with 50 small randomly scattered white squares (the first shader program), and a large red square (the second shader program).

In Safari Version 10.1 (12603.1.30.0.34) on macOS Sierra 10.12.4 (16E195) on a MacBook Air (13-inch, Mid 2013), and Safari on iOS 10.3.1 (14E304) on an iPhone 5S (NE433B/A), only the first draw works. You see only a black field with 50 small randomly scattered white squares (the first shader program). There is no large red square (the second shader program).

Removing either or both of these two lines from the first shader program's vertex shader will make the second draw work in Safari:

uniform vec2 uselessUniform1;
uniform float uselessUniform2;

That is, the number of uniforms in the first shader program affects whether the /second/ shader program will render successfully.

Whether or not the uniforms are actually in use seems to have no effect. The original program, from which this is cut down, actually made use of these uniforms, and had more of them.

Whether or not the first shader is rendered (i.e. commenting out its drawArrays call) also has no effect on the second shader not being rendered.

-- 
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/20170427/2e710699/attachment.html>


More information about the webkit-unassigned mailing list