asnfjksdll

This commit is contained in:
Tleety
2016-02-12 02:10:01 +01:00
parent 89cbc70177
commit f75f5f2471
7 changed files with 105 additions and 6 deletions
+12 -1
View File
@@ -1,16 +1,27 @@
#version 430
uniform vec2 PickingColor;
layout (binding = 0) uniform sampler2D Texture;
uniform vec4 Color;
uniform vec4 DiffuseColor;
uniform vec2 DiffuseUVRepeat;
in VertexData{
vec3 Position;
vec2 TextureCoord;
}Input;
out vec4 TextureFragment;
void main()
{
TextureFragment = vec4(PickingColor/255, 0, 1);
vec4 diffuseTexel = texture2D(Texture, Input.TextureCoord * DiffuseUVRepeat);
if(Color.a * diffuseTexel.a >= 0.9) {
TextureFragment = vec4(PickingColor/255, 0, 1);
}
}
+2
View File
@@ -12,10 +12,12 @@ layout(location = 4) in vec2 TextureCoords;
out VertexData{
vec3 Position;
vec2 TextureCoord;
}Output;
void main()
{
gl_Position = P*V*M * vec4(Position, 1.0);
Output.Position = Position, 1.0;
Output.TextureCoord = TextureCoords;
}
@@ -15,6 +15,7 @@ layout(location = 6) in vec4 BoneWeights;
out VertexData{
vec3 Position;
vec2 TextureCoord;
}Output;
void main()
@@ -29,4 +30,5 @@ void main()
gl_Position = P*V*M*boneTransform * vec4(Position, 1.0);
Output.Position = (boneTransform * vec4(Position, 1.0)).xyz;
Output.TextureCoord = TextureCoords;
}
+1 -1
View File
@@ -34,7 +34,7 @@ void main()
}
sceneColor = vec4(color_result.xyz, clamp(color_result.a, 0, 1));
bloomColor = vec4(clamp((glowTexel.xyz*3) - 1.0, 0, 100), 1.0);
//bloomColor = vec4(clamp((glowTexel.xyz*3) - 1.0, 0, 100), 1.0);
}