Created
March 22, 2018 18:46
-
-
Save raganmd/b1c313e57ece3d052e28c694807f9d70 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// TouchDesigner frag shader | |
// struct and data from our vertex shader | |
in VS_OUT{ | |
vec4 position; | |
vec3 normal; | |
vec4 color; | |
vec2 uv; | |
} fs_in; | |
// color buffer assignments | |
layout (location = 0) out vec4 o_position; | |
layout (location = 1) out vec4 o_normal; | |
layout (location = 2) out vec4 o_color; | |
layout (location = 3) out vec4 o_uv; | |
void main(){ | |
o_position = fs_in.position; | |
o_normal = vec4( fs_in.normal, 1.0 ); | |
o_color = fs_in.color; | |
o_uv = vec4( fs_in.uv, 0.0, 1.0 ); | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment