Shader looks jagged when the object is rotated

:information_source: Attention Topic was automatically imported from the old Question2Answer platform.
:bust_in_silhouette: Asked By Necronomicron

Hello!
I have a Polygon2D with a simple shader:

shader_type canvas_item;

void fragment()
{
	vec2 uv = UV + 0.5;
	vec3 color = fract(vec3(uv * 20.0, 0.5));
	COLOR = vec4(color, 1.0);
}

It looks OK until I rotate the polygon:

Any way to fix these jags?