summary refs log tree commit diff
path: root/shaders/shader.frag
diff options
context:
space:
mode:
Diffstat (limited to 'shaders/shader.frag')
-rw-r--r--shaders/shader.frag5
1 files changed, 3 insertions, 2 deletions
diff --git a/shaders/shader.frag b/shaders/shader.frag
index 20550ba..a2561d1 100644
--- a/shaders/shader.frag
+++ b/shaders/shader.frag
@@ -1,6 +1,7 @@
 #version 460
 
-layout(binding = 1) uniform sampler2D textureSampler;
+layout(binding = 1) uniform sampler textureSampler;
+layout(binding = 2) uniform texture2D textureImage;
 
 layout(location = 0) in vec3 fragmentColor;
 layout(location = 1) in vec2 fragmentTextureCoordinate;
@@ -9,7 +10,7 @@ layout(location = 0) out vec4 outColor;
 
 void main() {
   outColor = vec4(fragmentColor
-                      * texture(textureSampler,
+                      * texture(sampler2D(textureImage, textureSampler),
                                 fragmentTextureCoordinate).rgb,
                   1.0);
 }