diff options
author | Clément Foucault <foucault.clem@gmail.com> | 2019-06-27 18:01:28 +0300 |
---|---|---|
committer | Clément Foucault <foucault.clem@gmail.com> | 2019-06-27 18:02:22 +0300 |
commit | c5eceb35829560dcb7e31e0c41bf59ea4feec0c0 (patch) | |
tree | 61d9bf72aac0639038906e37552e29f33a33d90c /source | |
parent | 19d90c8602193f370c8d47805c82f16d9e6c18c0 (diff) |
Cleanup: EditMode: Remove uneeded shader depth bias
The bias is done using the DRWView now, no need to double it.
Diffstat (limited to 'source')
-rw-r--r-- | source/blender/draw/modes/shaders/edit_mesh_overlay_vert.glsl | 12 |
1 files changed, 0 insertions, 12 deletions
diff --git a/source/blender/draw/modes/shaders/edit_mesh_overlay_vert.glsl b/source/blender/draw/modes/shaders/edit_mesh_overlay_vert.glsl index fabc317cf4f..af0a47f1858 100644 --- a/source/blender/draw/modes/shaders/edit_mesh_overlay_vert.glsl +++ b/source/blender/draw/modes/shaders/edit_mesh_overlay_vert.glsl @@ -1,7 +1,6 @@ uniform float faceAlphaMod; uniform ivec4 dataMask = ivec4(0xFF); -uniform float ofs; in ivec4 data; in vec3 pos; @@ -23,24 +22,13 @@ void main() GPU_INTEL_VERTEX_SHADER_WORKAROUND vec3 world_pos = point_object_to_world(pos); - -#if !defined(FACE) - /* TODO override the ViewProjection Matrix for this case. */ - mat4 projmat = ProjectionMatrix; - projmat[3][2] -= ofs; - - gl_Position = projmat * (ViewMatrix * vec4(world_pos, 1.0)); -#else - gl_Position = point_world_to_ndc(world_pos); -#endif ivec4 m_data = data & dataMask; #if defined(VERT) finalColor = EDIT_MESH_vertex_color(m_data.y); gl_PointSize = sizeVertex * 2.0; - gl_Position.z -= 3e-5 * ((ProjectionMatrix[3][3] == 0.0) ? 1.0 : 0.0); /* Make selected and active vertex always on top. */ if ((data.x & VERT_SELECTED) != 0) { gl_Position.z -= 1e-7; |