We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 4908a99 commit 917182dCopy full SHA for 917182d
lib/triangle-vertex.glsl
@@ -28,7 +28,7 @@ vec3 getOrthogonalVector(vec3 v) {
28
// From the above if-statement we have ||a|| > 0 U ||b|| > 0.
29
// Assign z = 0, x = -b, y = a:
30
// a*-b + b*a + c*0 = -ba + ba + 0 = 0
31
- if (v.x*v.x > 0.1 || v.y*v.y > 0.1) {
+ if (v.x*v.x > v.z*v.z || v.y*v.y > v.z*v.z) {
32
return normalize(vec3(-v.y, v.x, 0.0));
33
} else {
34
return normalize(vec3(0.0, v.z, -v.y));
0 commit comments