Files
QIDIStudio/resources/shaders/140/mm_contour.fs

13 lines
352 B
Forth
Raw Normal View History

2025-05-05 14:58:54 +08:00
#version 140
2024-09-03 09:34:33 +08:00
const float EPSILON = 0.0001;
2025-05-05 14:58:54 +08:00
out vec4 frag_color;
2024-09-03 09:34:33 +08:00
void main()
{
2025-05-05 14:58:54 +08:00
frag_color = vec4(1.0, 1.0, 1.0, 1.0);
2024-09-03 09:34:33 +08:00
// Values inside depth buffer for fragments of the contour of a selected area are offset
// by small epsilon to solve z-fighting between painted triangles and contour lines.
gl_FragDepth = gl_FragCoord.z - EPSILON;
}