@vs vs
uniform vs_params {
mat4 mvp;
};
in vec4 position;
in vec2 texcoord0;
out vec4 color;
out vec2 uv;
void main() {
gl_Position = mvp * position;
uv = texcoord0;
}
@end
@fs fs
uniform texture2D tex;
uniform sampler smp;
in vec2 uv;
out vec4 frag_color;
void main() {
frag_color = texture(sampler2D(tex,smp), uv);
}
@end
@program texcube vs fs
The error as followings:
./sokol-shdc --input shd.glsl --output shd.h --slang glsl300es -f bare
shd.glsl:29:0: error: outputs of vs 'vs' don't match inputs of fs 'fs' for attr #0 (vs=color,fs=uv)
The code failed to run with shdc.
The error as followings:
The
out vec4 color;
at line 9 should be removed.