Backed out changeset 7272b7396c78 (bug 1932758) for causing fenix debug failures...
[gecko.git] / dom / canvas / test / webgl-conf / checkout / conformance2 / glsl3 / uniform-block-layouts.html
blob2dbfc664ee56ee95507589a497f53b1a708718e5
1 <!--
2 Copyright (c) 2019 The Khronos Group Inc.
3 Use of this source code is governed by an MIT-style license that can be
4 found in the LICENSE.txt file.
5 -->
7 <!DOCTYPE html>
8 <html>
9 <head>
10 <meta charset="utf-8">
11 <title>Disallowed uniform block layouts</title>
12 <link rel="stylesheet" href="../../resources/js-test-style.css"/>
13 <script src="../../js/js-test-pre.js"></script>
14 <script src="../../js/webgl-test-utils.js"></script>
15 <script src="../../js/glsl-conformance-test.js"></script>
16 </head>
17 <body>
18 <div id="description"></div>
19 <div id="console"></div>
20 <script id="fshaderPackedUniformBlock" type="x-shader/x-fragment">#version 300 es
21 precision mediump float;
23 out vec4 my_FragColor;
24 layout(packed) uniform foo {
25 vec4 bar;
28 void main() {
29 my_FragColor = bar;
31 </script>
32 <script id="fshaderSharedUniformBlock" type="x-shader/x-fragment">#version 300 es
33 precision mediump float;
35 out vec4 my_FragColor;
36 layout(shared) uniform foo {
37 vec4 bar;
40 void main() {
41 my_FragColor = bar;
43 </script>
44 <script type="application/javascript">
45 "use strict";
46 description("WebGL does not allow interface blocks with shared or packed layouts.");
48 GLSLConformanceTester.runTests([
50 fShaderId: 'fshaderPackedUniformBlock',
51 fShaderSuccess: false,
52 passMsg: 'Packed uniform buffers are disallowed'
55 fShaderId: 'fshaderSharedUniformBlock',
56 fShaderSuccess: false,
57 passMsg: 'Shared uniform buffers are disallowed'
59 ], 2);
60 </script>
61 </body>
62 </html>