mirror of
https://git.mirrors.martin98.com/https://github.com/prusa3d/PrusaSlicer.git
synced 2025-08-17 00:45:55 +08:00
Port of the changes made with a4435d214f3c5ed4111e474666fde5d431ea3501 to OpenGL ES
This commit is contained in:
parent
b27869dab8
commit
a1e4ce628a
@ -2,6 +2,7 @@
|
||||
|
||||
uniform mat4 view_model_matrix;
|
||||
uniform mat4 projection_matrix;
|
||||
uniform float offset;
|
||||
|
||||
attribute vec3 v_position;
|
||||
|
||||
@ -9,6 +10,6 @@ void main()
|
||||
{
|
||||
// Add small epsilon to z to solve z-fighting between painted triangles and contour lines.
|
||||
vec4 clip_position = projection_matrix * view_model_matrix * vec4(v_position, 1.0);
|
||||
clip_position.z -= 0.00001 * abs(clip_position.w);
|
||||
clip_position.z -= offset * abs(clip_position.w);
|
||||
gl_Position = clip_position;
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user