• 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    GL_EXT_primitive_bounding_box extension tests
20
21Tests:
22 + dEQP-GLES31.functional.primitive_bounding_box.*
23
24Includes:
25 + State query tests
26 + Primitive render tests
27   - All basic primitives: triangles, (wide) lines, (wide) points
28   - Set bounding box with gl_BoundingBoxEXT and PrimitiveBoundingBoxEXT
29   - Rendering with and without tessellation and/or geometry stages
30   - Rendering with correct, too large, and too small bounding boxes
31 + Depth render tests
32   - Render pattern and hint the final depth range with bounding box
33   - Test with built-in depth and user defined (gl_FragDepth) depth
34 + Blit tests
35   - Blit should not be affected by the bounding box
36 + Clear tests
37   - Clears should not be affected by the bounding box
38
39Excludes:
40 + Special floating point values (NaN, Inf, etc.)
41 + Rendering with separate shader pipelines
42 + Rendering discardable geometry with fragment shaders that have
43   side-effects (memory writes)
44 + Rendering discardable geometry with active transform feedback
45
46Description:
47
48state_query.* cases test the global PRIMITIVE_BOUNDING_BOX_EXT state.
49Tests set the state to certain values and then query the state using
50different methods.
51
52triangles.*, (wide_)lines.*, (wide_)points.* cases set the primitive
53bounding box and render a test pattern. Rendering results within the
54bounding box are then verified.
55
56"global_state.*" cases set the bounding box of the whole test pattern
57using the PRIMITIVE_BOUNDING_BOX_EXT state. "tessellation_set_per_draw.*"
58cases set the bounding box of the whole test pattern using
59gl_BoundingBoxEXT output variable. "tessellation_set_per_draw.*" cases
60set the bounding box for each (tessellation input) primitive separately.
61
62"*_bbox_equal" cases set the bounding box to tightly cover the primitive
63or the whole pattern. In "*_bbox_larger" cases, the bounding box is set
64to be larger than the rendered pattern/primitive and in "*_bbox_smaller"
65cases, the bounding box is set to cover only a subset of the pattern.
66In these subset cases, only the area covered by the bounding box is
67verified.
68
69triangles.* cases render a grid with yellow and green cells. Cells are
70in random order. Result image verification is done by simply checking
71that the viewport does not contain any background-colored pixels within
72the pattern area.
73
74(wide_)points.* cases render a pattern of green and blue points.
75Verification checks that no points within the bounding box area are
76missing and have the correct size. Size test is intended to prevent
77partially rendered points from passing the test.
78
79(wide_)lines.* cases render a pattern of green and blue lines.
80Verification checks the number and the width of separate lines within
81bounding box area. Number-of-lines check prevents accepting rendering
82results with missing lines and the line width check prevents accepting
83partially rendered lines.
84
85depth.* cases render multiple layers with varying depth values while
86hint the resulting depth range with primitive bounding box. In
87"builtin_depth.*" cases, depth is set by the rasterizer. In
88"user_defined_depth.*" cases, depth is set in the fragment shader using
89gl_FragDepth. Verification checks that only the topmost layer is visible.
90
91blit_fbo.* cases do framebuffer blits with different bounding box values.
92Bounding box values should not affect blitting.
93
94clear.* cases do full and scissored framebuffer clears. Since clears are
95not affected by the bounding box, verification is done by simply comparing
96rendering result with bounding box set to cover full viewport and rendering
97result with bounding box set to arbitrary values. In *_with_triangles cases,
98some geometry is rendered between clears with properly set bounding box.
99
100call_order.* cases render a scene with different relative order of
101glViewport and glPrimitiveBoundingBox. Tests verify that the bounding box
102for a draw command is calculated from the current state when draw command
103is issued (i.e. changing call order of state setting functions does not
104change ther result).
105