1e5c31af7Sopenharmony_ci-------------------------------------------------------------------------
2e5c31af7Sopenharmony_cidrawElements Quality Program Test Specification
3e5c31af7Sopenharmony_ci-----------------------------------------------
4e5c31af7Sopenharmony_ci
5e5c31af7Sopenharmony_ciCopyright 2014 The Android Open Source Project
6e5c31af7Sopenharmony_ci
7e5c31af7Sopenharmony_ciLicensed under the Apache License, Version 2.0 (the "License");
8e5c31af7Sopenharmony_ciyou may not use this file except in compliance with the License.
9e5c31af7Sopenharmony_ciYou may obtain a copy of the License at
10e5c31af7Sopenharmony_ci
11e5c31af7Sopenharmony_ci     http://www.apache.org/licenses/LICENSE-2.0
12e5c31af7Sopenharmony_ci
13e5c31af7Sopenharmony_ciUnless required by applicable law or agreed to in writing, software
14e5c31af7Sopenharmony_cidistributed under the License is distributed on an "AS IS" BASIS,
15e5c31af7Sopenharmony_ciWITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
16e5c31af7Sopenharmony_ciSee the License for the specific language governing permissions and
17e5c31af7Sopenharmony_cilimitations under the License.
18e5c31af7Sopenharmony_ci-------------------------------------------------------------------------
19e5c31af7Sopenharmony_ci	Fence sync tests
20e5c31af7Sopenharmony_ci
21e5c31af7Sopenharmony_ciTests:
22e5c31af7Sopenharmony_ci + dEQP-GLES3.functional.fence_sync.*
23e5c31af7Sopenharmony_ci
24e5c31af7Sopenharmony_ciIncludes:
25e5c31af7Sopenharmony_ci + Creating and deleting sync objects
26e5c31af7Sopenharmony_ci + Calling glWaitSync
27e5c31af7Sopenharmony_ci	- With varying number of primitive draws
28e5c31af7Sopenharmony_ci + Calling glClientWaitSync and verifying return values
29e5c31af7Sopenharmony_ci	- With varying number of primitive draws
30e5c31af7Sopenharmony_ci	- With varying timeouts
31e5c31af7Sopenharmony_ci	- Flushing or finishing before wait
32e5c31af7Sopenharmony_ci
33e5c31af7Sopenharmony_ciDescription:
34e5c31af7Sopenharmony_ci
35e5c31af7Sopenharmony_ciFence sync functionality is tested by drawing a small or large number of
36e5c31af7Sopenharmony_ciprimitives with glDrawArrays(). Then a sync object is created, and
37e5c31af7Sopenharmony_cioptionally glFlush() or glFinish() are called.
38e5c31af7Sopenharmony_ci
39e5c31af7Sopenharmony_ciWait is then performed with either glWaitSync() or glClientWaitSync(), and
40e5c31af7Sopenharmony_cidifferent timeout values as well as the flag GL_SYNC_FLUSH_COMMANDS_BIT
41e5c31af7Sopenharmony_ciare tested. Finally, errors are checked and the return value of
42e5c31af7Sopenharmony_ciglClientWaitSync() is verified.
43e5c31af7Sopenharmony_ci
44e5c31af7Sopenharmony_ciThe testcase fails if errors are created or if glClientWaitSync() returns
45e5c31af7Sopenharmony_ciGL_WAIT_FAILED. Additionally, if glFinish() was called before wait, return
46e5c31af7Sopenharmony_civalue is required to be GL_ALREADY_SIGNALED.
47