Improve error messages slightly;

This commit is contained in:
bjorn 2018-08-03 13:19:28 -07:00
parent 66c1f373d3
commit b33e0e33c5
1 changed files with 3 additions and 3 deletions

View File

@ -1622,9 +1622,9 @@ void lovrShaderSetBlock(Shader* shader, const char* name, ShaderBlock* source) {
for (int i = 0; i < block->uniforms.length; i++) {
const Uniform* u = &block->uniforms.data[i];
const Uniform* v = &source->uniforms.data[i];
lovrAssert(u->offset == v->offset, ""); // TODO
lovrAssert(u->size == v->size, ""); // TODO
lovrAssert(u->type == v->type, ""); // TODO
lovrAssert(u->type == v->type, "Shader is not compatible with ShaderBlock, check type of variable '%s'", v->name);
lovrAssert(u->offset == v->offset, "Shader is not compatible with ShaderBlock, check variable '%s'", v->name);
lovrAssert(u->size == v->size, "Shader is not compatible with ShaderBlock, check variable '%s'", v->name);
}
}