vulkan-tutorial/shadersrc/rainbow_lit.frag

22 lines
528 B
GLSL
Raw Permalink Normal View History

2023-04-02 08:46:02 +00:00
#version 450
// shader input
layout(location = 0) in vec4 fragColor;
// output write
layout(location = 0) out vec4 outColor;
layout(set = 0, binding = 1) uniform SceneData{
vec4 fogColor; // w is for exponent
vec4 fogDistances; //x for min, y for max, zw unused.
vec4 ambientColor;
vec4 sunlightDirection; //w for sun power
vec4 sunlightColor;
} sceneData;
void main() {
2023-04-19 15:26:33 +00:00
outColor = vec4(fragColor.xyz + sceneData.ambientColor.xyz, 1.0f);
//outColor = fragColor;
2023-04-19 13:38:54 +00:00
//outColor = sceneData.ambientColor;
2023-04-02 08:46:02 +00:00
}