working on additive blending for determination of winding order. Saving here because this bug is very pretty

This commit is contained in:
2020-02-22 01:37:47 -08:00
parent b3e092e25a
commit 5dde94cdf9
7 changed files with 97 additions and 35 deletions

View File

@@ -7,7 +7,12 @@ layout(location = 0) in vec4 out_color;
layout(location = 0) out vec4 f_color;
void main() {
f_color = out_color;
if (int(out_color.w) % 2 == 0) {
f_color = out_color;
f_color.w = 255.0;
}
}

View File

@@ -10,6 +10,8 @@ layout(location = 0) out vec4 out_color;
void main() {
out_color = color;
gl_Position = vec4(v_position, 1.0);
}

View File

@@ -8,5 +8,13 @@ layout(location = 0) in vec4 out_color;
layout(location = 0) out vec4 f_color;
void main() {
f_color = out_color;
if (int(out_color.w) % 2 == 0) {
f_color = out_color;
f_color.w = 255.0;
}
//f_color = out_color;
}