mirror of
https://github.com/FirestormViewer/phoenix-firestorm.git
synced 2026-08-14 00:48:30 +00:00
secondlife/viewer#3584 Fix avatar body mesh and system clothing conflicting with water and alpha due to missing discard of invisible pixels (FS:TJ cherry-pick to fix FIRE-36310)
This commit is contained in:
@@ -51,9 +51,7 @@ in vec3 vary_norm;
|
||||
in vec4 vertex_color; //vertex color should be treated as sRGB
|
||||
#endif
|
||||
|
||||
#ifdef HAS_ALPHA_MASK
|
||||
uniform float minimum_alpha;
|
||||
#endif
|
||||
|
||||
uniform mat4 proj_mat;
|
||||
uniform mat4 inv_proj;
|
||||
@@ -225,6 +223,13 @@ void main()
|
||||
|
||||
float final_alpha = diffuse_linear.a;
|
||||
|
||||
#ifdef IS_AVATAR_SKIN
|
||||
if(final_alpha < minimum_alpha)
|
||||
{
|
||||
discard;
|
||||
}
|
||||
#endif
|
||||
|
||||
#ifdef USE_VERTEX_COLOR
|
||||
final_alpha *= vertex_color.a;
|
||||
|
||||
|
||||
Reference in New Issue
Block a user