Changeset e1a7f5a in opengl-game for shaders


Ignore:
Timestamp:
Aug 16, 2019, 3:47:01 PM (5 years ago)
Author:
Dmitry Portnoy <dmitry.portnoy@…>
Branches:
feature/imgui-sdl, master, points-test
Children:
5936c58
Parents:
5f3dba8
Message:

Copy an SDL Texture to a Vulkan texture to use as a UI overlay on the 3D scene

Location:
shaders
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • shaders/shader.frag

    r5f3dba8 re1a7f5a  
    1313void main() {
    1414   if (isOverlay == 1) {
    15       outColor = vec4(fragColor * texture(uiTexSampler, fragTexCoord).rgb, 0.3);
     15      outColor = vec4(fragColor * texture(uiTexSampler, fragTexCoord).rgb, 1.0);
    1616   } else {
    1717      outColor = vec4(fragColor * texture(texSampler, fragTexCoord).rgb, 1.0);
  • shaders/shader.vert

    r5f3dba8 re1a7f5a  
    2323   } else {
    2424      gl_Position = vec4(inPosition, 1.0);
    25       fragColor = vec3(0.0, 1.0, 1.0);
     25      fragColor = vec3(1.0, 1.0, 1.0);
    2626      isOverlay = 1;
    2727   }
Note: See TracChangeset for help on using the changeset viewer.