Graphic tweaks/cleanup
This commit is contained in:
@@ -1,13 +1,13 @@
|
||||
#version 450 core
|
||||
layout(early_fragment_tests) in;
|
||||
layout (std140, binding = 1) uniform TheLight { vec4 lightPos; vec4 lumRad; };
|
||||
layout (binding = 0) uniform sampler2D screenTexture;
|
||||
layout (binding = 0) uniform sampler2D posTexture;
|
||||
layout (binding = 1) uniform sampler2D normals;
|
||||
in vec2 vTexPos;
|
||||
out vec4 fColor;
|
||||
float rad = lumRad.a;
|
||||
void main() {
|
||||
vec3 pos = texture(screenTexture, vTexPos).xyz;
|
||||
vec3 pos = texture(posTexture, vTexPos).xyz;
|
||||
vec3 distVec = pos - lightPos.xyz;
|
||||
float dist = dot(distVec, distVec);
|
||||
vec3 norm = texture(normals, vTexPos).xyz;
|
||||
|
||||
@@ -1,13 +1,13 @@
|
||||
#version 450 core
|
||||
layout(early_fragment_tests) in;
|
||||
layout (std140, binding = 1) uniform TheLight { vec4 lightPos; vec4 lumRad; };
|
||||
layout (binding = 0) uniform sampler2D screenTexture;
|
||||
layout (binding = 0) uniform sampler2D posTexture;
|
||||
layout (binding = 1) uniform sampler2D normals;
|
||||
in vec2 vTexPos;
|
||||
out vec4 fColor;
|
||||
float rad = lumRad.a;
|
||||
void main() {
|
||||
vec3 pos = texture(screenTexture, vTexPos).xyz;
|
||||
vec3 pos = texture(posTexture, vTexPos).xyz;
|
||||
vec3 distVec = pos - lightPos.xyz;
|
||||
float dist = dot(distVec, distVec);
|
||||
// float dist = dot(distVec.xy, distVec.xy);
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
#version 450 core
|
||||
layout (std140, binding = 2) uniform PosTex { vec4 posTex[6]; };
|
||||
layout (std140, binding = 2) uniform PosTex { vec4 posTex[3]; };
|
||||
out vec2 vTexPos;
|
||||
void main() {
|
||||
gl_Position = vec4(posTex[gl_VertexID].xy,0,1);
|
||||
|
||||
Reference in New Issue
Block a user