Changeset e5d4aca in opengl-game for shaders/overlay.frag
- Timestamp:
- Aug 22, 2019, 2:19:56 AM (6 years ago)
- Branches:
- feature/imgui-sdl, master, points-test
- Children:
- 6544020
- Parents:
- c8c6da8
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
shaders/overlay.frag
rc8c6da8 re5d4aca 2 2 #extension GL_ARB_separate_shader_objects : enable 3 3 4 layout(binding = 1) uniform sampler2D texSampler; 5 layout(binding = 2) uniform sampler2D uiTexSampler; 4 layout(binding = 0) uniform sampler2D uiTexSampler; 6 5 7 6 layout(location = 0) in vec3 fragColor; … … 12 11 13 12 void main() { 13 outColor = texture(uiTexSampler, fragTexCoord); 14 14 15 if (isOverlay == 1) { 15 16 outColor = texture(uiTexSampler, fragTexCoord); 16 17 } else { 17 outColor = vec4(fragColor * texture( texSampler, fragTexCoord).rgb, 1.0);18 outColor = vec4(fragColor * texture(uiTexSampler, fragTexCoord).rgb, 1.0); 18 19 } 19 20 }
Note:
See TracChangeset
for help on using the changeset viewer.