mirror of
https://github.com/orange-cpp/omath.git
synced 2026-04-18 18:43:27 +00:00
Use dot not quad
This commit is contained in:
@@ -30,6 +30,11 @@ in vec3 vColor;
|
||||
out vec4 FragColor;
|
||||
|
||||
void main() {
|
||||
// Calculate distance from center of the point
|
||||
vec2 coord = gl_PointCoord - vec2(0.5);
|
||||
if(length(coord) > 0.5)
|
||||
discard;
|
||||
|
||||
FragColor = vec4(vColor, 1.0);
|
||||
}
|
||||
)";
|
||||
|
||||
Reference in New Issue
Block a user