Loads and loads of small improvements I added while developing on my game
This commit is contained in:
parent
41421b1df9
commit
a7c71e7ea1
107 changed files with 2278 additions and 1023 deletions
|
|
@ -1,20 +1,6 @@
|
|||
#version 330
|
||||
//# region vertex
|
||||
|
||||
//# import SM_base_vertex_basic
|
||||
void ApplyTexModifier();
|
||||
void CheckVertexColor();
|
||||
void ApplyModelTransformation();
|
||||
|
||||
void vmain() {
|
||||
ApplyTexModifier();
|
||||
CheckVertexColor();
|
||||
ApplyModelTransformation();
|
||||
}
|
||||
|
||||
//# region fragment
|
||||
in vec2 vTexture;
|
||||
in vec4 vColor;
|
||||
in vec2 v_TexCoords;
|
||||
in vec4 v_Color;
|
||||
|
||||
uniform vec4 Tint;
|
||||
uniform bool UseTexture;
|
||||
|
|
@ -22,7 +8,9 @@ uniform sampler2D Texture;
|
|||
|
||||
layout(location = 0) out vec4 color;
|
||||
|
||||
void fmain() {
|
||||
color = vColor * Tint;
|
||||
if (UseTexture) color *= texture(Texture, vTexture);
|
||||
void main() {
|
||||
color = vec4(v_TexCoords, 0, 1);
|
||||
return;
|
||||
color = v_Color * Tint;
|
||||
if (UseTexture) color = texture(Texture, v_TexCoords);
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue