Vulkan: Image Editor Drawing

When drawing the image editor the depth of the geometry is set to -1.
This will be clipped in Vulkan, but is valid in OpenGL. This PR patches
the shader to be inside the range that both Vulkan and OpenGL support.

This ensures that images are visible in the image editor.

Pull Request: https://projects.blender.org/blender/blender/pulls/113668
This commit is contained in:
Jeroen Bakker
2023-10-13 12:54:23 +02:00
parent 751133c40e
commit a0ef7a7910
2 changed files with 2 additions and 0 deletions

View File

@@ -10,5 +10,6 @@ void main()
uv_screen = image_pos.xy;
vec4 position = point_world_to_ndc(image_pos);
position.z = 0.0;
gl_Position = position;
}

View File

@@ -10,5 +10,6 @@ void main()
uv_image = uv;
vec4 position = point_world_to_ndc(image_pos);
position.z = 0.0;
gl_Position = position;
}