2016-08-15 15:17:01 +02:00
|
|
|
#version 450
|
|
|
|
|
|
|
|
|
|
#extension GL_ARB_separate_shader_objects : enable
|
|
|
|
|
#extension GL_ARB_shading_language_420pack : enable
|
|
|
|
|
|
|
|
|
|
layout (set = 0, binding = 1) uniform texture2D textureColor;
|
|
|
|
|
layout (set = 0, binding = 2) uniform sampler samplers[3];
|
|
|
|
|
|
|
|
|
|
layout (location = 0) in vec2 inUV;
|
|
|
|
|
layout (location = 1) in float inLodBias;
|
2016-08-30 20:45:23 +02:00
|
|
|
layout (location = 2) flat in int inSamplerIndex;
|
2016-08-15 15:17:01 +02:00
|
|
|
|
|
|
|
|
layout (location = 0) out vec4 outFragColor;
|
|
|
|
|
|
|
|
|
|
void main()
|
|
|
|
|
{
|
2016-08-30 20:45:23 +02:00
|
|
|
outFragColor = texture(sampler2D(textureColor, samplers[inSamplerIndex]), inUV, inLodBias);
|
2016-08-15 15:17:01 +02:00
|
|
|
}
|