mirror of
https://github.com/KevinMidboe/linguist.git
synced 2025-10-29 17:50:22 +00:00
Added GLSL extensions .vsh & .fsh (#2951)
This commit is contained in:
@@ -1125,6 +1125,7 @@ GLSL:
|
||||
- .frag
|
||||
- .frg
|
||||
- .fs
|
||||
- .fsh
|
||||
- .fshader
|
||||
- .geo
|
||||
- .geom
|
||||
@@ -1133,6 +1134,7 @@ GLSL:
|
||||
- .shader
|
||||
- .vert
|
||||
- .vrx
|
||||
- .vsh
|
||||
- .vshader
|
||||
ace_mode: glsl
|
||||
|
||||
|
||||
20
samples/GLSL/gbuffers_textured_lit.fsh
Normal file
20
samples/GLSL/gbuffers_textured_lit.fsh
Normal file
@@ -0,0 +1,20 @@
|
||||
#version 120
|
||||
|
||||
uniform sampler2D texture;
|
||||
|
||||
varying vec3 color;
|
||||
varying vec2 texcoord;
|
||||
|
||||
vec4 GetDiffuse() {
|
||||
vec4 diffuse = vec4(color.rgb, 1.0);
|
||||
diffuse *= texture2D(texture, texcoord);
|
||||
|
||||
return diffuse;
|
||||
}
|
||||
|
||||
|
||||
void main() {
|
||||
vec4 diffuse = GetDiffuse();
|
||||
|
||||
gl_FragData[0] = diffuse;
|
||||
}
|
||||
11
samples/GLSL/gbuffers_textured_lit.vsh
Normal file
11
samples/GLSL/gbuffers_textured_lit.vsh
Normal file
@@ -0,0 +1,11 @@
|
||||
#version 120
|
||||
|
||||
varying vec3 color;
|
||||
varying vec2 texcoord;
|
||||
|
||||
void main() {
|
||||
color = gl_Color.rgb;
|
||||
texcoord = gl_MultiTexCoord0.st;
|
||||
|
||||
gl_Position = ftransform();
|
||||
}
|
||||
Reference in New Issue
Block a user