mirror of
https://github.com/yuzu-emu/yuzu.git
synced 2024-07-04 23:31:19 +01:00
Report shader uniform block size in case of mismatch
This commit is contained in:
parent
0edc986861
commit
4088afe23c
1 changed files with 3 additions and 1 deletions
|
@ -1083,7 +1083,9 @@ void RasterizerOpenGL::SetShader() {
|
||||||
GLint block_size;
|
GLint block_size;
|
||||||
glGetActiveUniformBlockiv(current_shader->shader.handle, block_index,
|
glGetActiveUniformBlockiv(current_shader->shader.handle, block_index,
|
||||||
GL_UNIFORM_BLOCK_DATA_SIZE, &block_size);
|
GL_UNIFORM_BLOCK_DATA_SIZE, &block_size);
|
||||||
ASSERT_MSG(block_size == sizeof(UniformData), "Uniform block size did not match!");
|
ASSERT_MSG(block_size == sizeof(UniformData),
|
||||||
|
"Uniform block size did not match! Got %d, expected %zu",
|
||||||
|
static_cast<int>(block_size), sizeof(UniformData));
|
||||||
glUniformBlockBinding(current_shader->shader.handle, block_index, 0);
|
glUniformBlockBinding(current_shader->shader.handle, block_index, 0);
|
||||||
|
|
||||||
// Update uniforms
|
// Update uniforms
|
||||||
|
|
Loading…
Reference in a new issue