You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
20 lines
368 B
20 lines
368 B
#version 450
|
|
|
|
layout (location = 0) out vec4 color;
|
|
|
|
layout (location = 0) uniform struct {
|
|
float r;
|
|
float g;
|
|
float b;
|
|
} parts[2] = { { 1.0, 1.0, 1.0}, { 0.0, 1.0, 0.0 } };
|
|
|
|
void main() {
|
|
color = vec4(0.0, 0.0, 0.0, 1.0);
|
|
|
|
for (int i = 0; i < 2; i++) {
|
|
color.r += parts[i].r;
|
|
color.g += parts[i].g;
|
|
color.b += parts[i].b;
|
|
}
|
|
}
|