Add support for loading amb green channels (shading)

This commit is contained in:
KillzXGaming 2019-12-19 20:17:20 -05:00
parent b1cf8a25a9
commit fbb86955ba

View file

@ -163,11 +163,11 @@ void main()
vec2 ambientUV = f_texcoord0;
ambientUV.x *= ColorUVScaleU + ColorUVTranslateU;
ambientUV.y *= ColorUVScaleV + ColorUVTranslateV;
float intensity = texture(AmbientMap, ambientUV).r;
float unknown = texture(AmbientMap, ambientUV).g; //Unsually black
float ambient = texture(AmbientMap, ambientUV).b;
float ambient = 1 - texture(AmbientMap, ambientUV).r;
float shadows = 1 - texture(AmbientMap, ambientUV).g; //Unsually black
float cavity = texture(AmbientMap, ambientUV).b;
ao = 1 - intensity;
ao = (ambient * shadows);
}
vec3 emissionTerm = vec3(0);