• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1-------------------------------------------------------------------------
2drawElements Quality Program Test Specification
3-----------------------------------------------
4
5Copyright 2014 The Android Open Source Project
6
7Licensed under the Apache License, Version 2.0 (the "License");
8you may not use this file except in compliance with the License.
9You may obtain a copy of the License at
10
11     http://www.apache.org/licenses/LICENSE-2.0
12
13Unless required by applicable law or agreed to in writing, software
14distributed under the License is distributed on an "AS IS" BASIS,
15WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
16See the License for the specific language governing permissions and
17limitations under the License.
18-------------------------------------------------------------------------
19    Explicit uniform location tests
20
21Tests:
22 + dEQP-GLES31.functional.uniform_location.*
23
24Includes:
25 + Location for all primitive types
26 + Location for (nested) structs and their members
27 + Location for (nested) arrays and all their elements
28 + Minimum and maximum location
29   - With all primitive types
30 + Linkage with locations defined in the vertex shader, fragment shader, both or neither
31   - Primitive types only
32 + Negative tests
33   - Duplicate location with various linkage and usage
34   - Overlapping structs and arrays with various linkage and usage
35
36Excludes:
37 + Samplers with dimensionality other than two or less than four color channels
38 + Deeply nested structs/arrays
39
40Description:
41
42All cases create a shader with suitable uniforms, some of which have layout
43qualifiers with a location specified. Locations of all uniforms in the shader
44are verified to match the given ones with glGetUniformLocation. Generated
45textures with a flat randomized color are bound to samplers. Other uniforms
46are assigned similarly randomized values.
47The shader contains hardcoded comparisons to these randomized values for each
48uniform that is being checked. It outputs white if all of the assigned uniform
49values match the hardcoded values. A quad is rendered and the output of the
50shader is verified to be fully white.
51
52All cases excluding negative and min/max use randomized locations between the
53spec defined minimum and maximum values [0, 1024) for all uniforms.
54
55Basic primitive type, array, nested array and min/max cases test with all basic
56types. Tests are done in both vertex and fragment shaders but with trivial
57linkage.
58
59Min/max cases assign a single primitive either the largest valid location as
60reported by the implementation or the smallest valid location (0) but are
61otherwise identical to the basic primitive type cases.
62
63Struct, nested struct and linkage cases are randomized.
64These cases do not necessarily use every declared uniform.
65These cases have declarations, locations specifiers and verification
66randomly split between the vertex and fragment shaders on a per-uniform basis.
67This includes leaving some locations unassigned.
68All primitive types used in these tests are randomized.
69Struct cases have a fixed number of members with a fixed nesting structure.
70
71Negative cases are not generated and share no logic with the other cases,
72instead expecting compile or link failures.
73