41 lines · 1.0 KB · Text
RawDownload
<@include gpu/Config.slh@><$VERSION_HEADER$>//  Generated on <$_SCRIBE_DATE$>////  deferred_light.vert//  vertex shader////  Created by Sam Gateau on 6/16/16.//  Copyright 2014 High Fidelity, Inc.////  Distributed under the Apache License, Version 2.0.//  See the accompanying file LICENSE or http://www.apache.org/licenses/LICENSE-2.0.html// <@include render-utils/ShaderConstants.h@> OUTPUT(RENDER_UTILS_ATTR_TEXCOORD01, vec4, _texCoord01); void main(void) {    const float depth = 1.0;#ifdef VULKAN    const mat4 UNIT_QUAD = mat4(        vec4(-1.0, 1.0, depth, 1.0),        vec4(1.0, 1.0, depth, 1.0),        vec4(-1.0, -1.0, depth, 1.0),        vec4(1.0, -1.0, depth, 1.0)    );#else    const mat4 UNIT_QUAD = mat4(        vec4(-1.0, -1.0, depth, 1.0),        vec4(1.0, -1.0, depth, 1.0),        vec4(-1.0, 1.0, depth, 1.0),        vec4(1.0, 1.0, depth, 1.0)    );#endif    vec4 pos = UNIT_QUAD[gl_VertexID];     _texCoord01 = vec4((pos.xy + 1.0) * 0.5, 0.0, 0.0);     gl_Position = pos;}

Keyboard shortcuts

General

Show keyboard shortcuts
?
Focus the current search
/

Issues and pull requests

Open filters
f

Issues, pull requests and Inbox

Select next item
j↓
Select previous item
k↑
Open selected item
Enter
Dismiss filters or clear selection
Esc

Repository code

Go to file
t