Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMike Erwin <significant.bit@gmail.com>2016-09-13 09:51:38 +0300
committerMike Erwin <significant.bit@gmail.com>2016-09-13 09:51:38 +0300
commit1b5b899228bd63e34dd1c35ada8e0408983b8f38 (patch)
tree5136846b00081ad83a95ba1569d7d00a3b8fe43a /source/blender/gpu/shaders/gpu_shader_depth_only_frag.glsl
parentddb1d5648dbd6d5be8b7fd9df4d122e6df5b5ce3 (diff)
OpenGL: add built-in GPU_SHADER_3D_DEPTH_ONLY
We’re discussing several techniques that require a depth pre-pass.
Diffstat (limited to 'source/blender/gpu/shaders/gpu_shader_depth_only_frag.glsl')
-rw-r--r--source/blender/gpu/shaders/gpu_shader_depth_only_frag.glsl6
1 files changed, 6 insertions, 0 deletions
diff --git a/source/blender/gpu/shaders/gpu_shader_depth_only_frag.glsl b/source/blender/gpu/shaders/gpu_shader_depth_only_frag.glsl
new file mode 100644
index 00000000000..60e71e19004
--- /dev/null
+++ b/source/blender/gpu/shaders/gpu_shader_depth_only_frag.glsl
@@ -0,0 +1,6 @@
+
+void main()
+{
+ // no color output, only depth (line below is implicit)
+ // gl_FragDepth = gl_FragCoord.z;
+}