Changeset e5d4aca in opengl-game for shaders/overlay.frag


Ignore:
Timestamp:
Aug 22, 2019, 2:19:56 AM (6 years ago)
Author:
Dmitry Portnoy <dmitry.portnoy@…>
Branches:
feature/imgui-sdl, master, points-test
Children:
6544020
Parents:
c8c6da8
Message:

Create separate descriptor pools and descriptor sets for each shader group and start removing unnecessary elements from the overlay shaders

File:
1 edited

Legend:

Unmodified
Added
Removed
  • shaders/overlay.frag

    rc8c6da8 re5d4aca  
    22#extension GL_ARB_separate_shader_objects : enable
    33
    4 layout(binding = 1) uniform sampler2D texSampler;
    5 layout(binding = 2) uniform sampler2D uiTexSampler;
     4layout(binding = 0) uniform sampler2D uiTexSampler;
    65
    76layout(location = 0) in vec3 fragColor;
     
    1211
    1312void main() {
     13   outColor = texture(uiTexSampler, fragTexCoord);
     14
    1415   if (isOverlay == 1) {
    1516      outColor = texture(uiTexSampler, fragTexCoord);
    1617   } else {
    17       outColor = vec4(fragColor * texture(texSampler, fragTexCoord).rgb, 1.0);
     18      outColor = vec4(fragColor * texture(uiTexSampler, fragTexCoord).rgb, 1.0);
    1819   }
    1920}
Note: See TracChangeset for help on using the changeset viewer.