use vr hiddenarea mask

This commit is contained in:
milek7
2020-11-18 22:18:28 +01:00
parent 8889872f39
commit 79b0216b55
7 changed files with 82 additions and 7 deletions

15
shaders/hiddenarea.frag Normal file
View File

@@ -0,0 +1,15 @@
#include <common>
layout(location = 0) out vec4 out_color;
#if MOTIONBLUR_ENABLED
layout(location = 1) out vec4 out_motion;
#endif
void main()
{
out_color = vec4(vec3(0.0f), 1.0f);
#if MOTIONBLUR_ENABLED
out_motion = vec4(0.0f);
#endif
gl_FragDepth = 1.0f;
}

6
shaders/hiddenarea.vert Normal file
View File

@@ -0,0 +1,6 @@
layout(location = 0) in vec3 v_vert;
void main()
{
gl_Position = vec4(v_vert.xy * 2.0f - 1.0f, 0.5f, 1.0f);
}