1
0
mirror of https://github.com/EduApps-CDG/OpenDX synced 2024-12-30 09:45:37 +01:00
OpenDX/src/dxvk/shaders/dxvk_fullscreen_vert.vert
Philip Rebohle 07408bcdcc
[dxvk] Add new vertex and geometry shaders for fullscreen passes
These new shaders are aimed to be used by all meta operations
and will work without geometry shaders on supported hardware.
2019-07-18 18:57:15 +02:00

15 lines
320 B
GLSL

#version 450
layout(location = 0) out int o_instance;
layout(location = 1) out vec2 o_texcoord;
void main() {
vec2 coord = vec2(
float(gl_VertexIndex & 2),
float(gl_VertexIndex & 1) * 2.0f);
o_instance = gl_InstanceIndex;
o_texcoord = coord;
gl_Position = vec4(-1.0f + 2.0f * coord, 0.0f, 1.0f);
}