Fix link problem with shaders that use transparency and normal maps

This commit is contained in:
Brad Davis 2016-03-09 19:45:46 -08:00
parent f98b6c3a28
commit aad2aaa764
3 changed files with 7 additions and 1 deletions

View file

@ -26,10 +26,12 @@ out vec2 _texCoord0;
out vec3 _normal;
out vec3 _tangent;
out vec3 _color;
out float _alpha;
void main(void) {
// pass along the color
_color = colorToLinearRGB(inColor.xyz);
_color = colorToLinearRGB(inColor.rgb);
_alpha = inColor.a;
// and the texture coordinates
_texCoord0 = (texcoordMatrices[0] * vec4(inTexCoord0.xy, 0.0, 1.0)).st;

View file

@ -25,6 +25,7 @@ out vec4 _position;
out vec2 _texCoord0;
out vec3 _normal;
out vec3 _color;
out float _alpha;
void main(void) {
vec4 position = vec4(0.0, 0.0, 0.0, 0.0);
@ -34,6 +35,7 @@ void main(void) {
// pass along the color
_color = colorToLinearRGB(inColor.rgb);
_alpha = inColor.a;
// and the texture coordinates
_texCoord0 = (texcoordMatrices[0] * vec4(inTexCoord0.st, 0.0, 1.0)).st;

View file

@ -26,6 +26,7 @@ out vec2 _texCoord0;
out vec3 _normal;
out vec3 _tangent;
out vec3 _color;
out float _alpha;
void main(void) {
vec4 position = vec4(0.0, 0.0, 0.0, 0.0);
@ -36,6 +37,7 @@ void main(void) {
// pass along the color
_color = colorToLinearRGB(inColor.rgb);
_alpha = inColor.a;
// and the texture coordinates
_texCoord0 = (texcoordMatrices[0] * vec4(inTexCoord0.st, 0.0, 1.0)).st;