Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Clean up uniform buffer tests #2479

Merged
merged 1 commit into from Aug 12, 2017

Conversation

Oletus
Copy link
Contributor

@Oletus Oletus commented Aug 11, 2017

Uniform buffer draw tests can check that the uniform buffer is in the
std140 layout, since the WebGL spec mandates std140 layout. This makes
the tests simpler and enables sharing some common functionality
between subtests as well.

This refactoring is done to make way for a few more uniform buffer
tests that are needed for bugs that recently got fixed in ANGLE
related to structs in uniform blocks.

The test was also expecting that the value of
UNIFORM_BUFFER_OFFSET_ALIGNMENT was divisible by 4, but that was
somewhat non-obvious. The test for it is also clearer now. This
requirement didn't seem to be enshrined in the spec previously, but it
is reasonable and the test has been there for a while so put it in the
spec now.

Uniform buffer draw tests can check that the uniform buffer is in the
std140 layout, since the WebGL spec mandates std140 layout. This makes
the tests simpler and enables sharing some common functionality
between subtests as well.

This refactoring is done to make way for a few more uniform buffer
tests that are needed for bugs that recently got fixed in ANGLE
related to structs in uniform blocks.

The test was also expecting that the value of
UNIFORM_BUFFER_OFFSET_ALIGNMENT was divisible by 4, but that was
somewhat non-obvious. The test for it is also clearer now. This
requirement didn't seem to be enshrined in the spec previously, but it
is reasonable and the test has been there for a while so put it in the
spec now.
@kenrussell
Copy link
Member

Great updates. LGTM

@kenrussell kenrussell merged commit d54ac75 into KhronosGroup:master Aug 12, 2017
@Oletus Oletus deleted the interface-blocks-test branch August 12, 2017 09:32
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants