sokol-luajit/projects/examples/samples/cube-sapp.glsl

29 lines
353 B
Plaintext
Raw Normal View History

2024-10-08 16:47:56 +08:00
@ctype mat4 hmm_mat4
2026-07-30 22:59:09 +08:00
@vs vs_cube
layout(binding = 0, std140) uniform vs_params {
2024-10-08 16:47:56 +08:00
mat4 mvp;
};
in vec4 position;
in vec4 color0;
out vec4 color;
void main() {
gl_Position = mvp * position;
color = color0;
}
@end
2026-07-30 22:59:09 +08:00
@fs fs_cube
2024-10-08 16:47:56 +08:00
in vec4 color;
out vec4 frag_color;
void main() {
frag_color = color;
}
@end
2026-07-30 22:59:09 +08:00
@program cube vs_cube fs_cube