Closed mlomb closed 7 years ago
Thanks for the report. As you can see, I haven't work a lot with ESSL so far. I know there are a lot of differences between GLSL and ESSL, but I haven't had the time yet to gather much experience with ESSL.
Fixed with 56aee09.
I have problems trying to compile the same shader again, seems like it doesn't work when autoBinding is disabled. The location should be there even if the autoBinding is disabled, at least for ESSL3.0/1/2.
Also, doing some tests with the autoBinding enabled I found that the uniform blocks doesn't support binding:
layout(std140, row_major, binding = 0) uniform UBO
{
highp mat4 some_matrix;
};
Feel free re-open this issue. I'll take care of it tomorrow.
I can't reopen the issue if the owner (you) close it.
I maybe ran over this a little fast, so I'll take a closer look at it as soon as I can. Thanks and kind regards, Lukas
Should be fixed now with c268e07.
The binding
qualifier is only generated if -EB
is enabled and the output ESSL version is at least 310.
Let me know if there's still something wrong on this.
Lukas
Everything seems to be working fine :)
Input shader:
Output shader (ESSL300):
When compiling:
In ESSL 3.0 specification (4.3.8.2):
So it should specify the location if there is more than one output (or the auto binding is enabled).
Sidenote: The spec also says:
But the autoBinding add the layout qualifier anyway.
Spec: https://www.khronos.org/registry/OpenGL/specs/es/3.0/GLSL_ES_Specification_3.00.pdf