yum-mirror/glslang
git clone https://git.yummers.dev/yum-mirror/glslang
2f21fcce
main
1#version 110 2 3uniform float d ; 4uniform vec4 bigColor ,smallColor ; 5uniform vec4 otherColor ; 6 7varying float c ; 8 9uniform float threshhold ; 10uniform float threshhold2 ; 11uniform float threshhold3 ; 12 13uniform float minimum ; 14 15varying vec4 BaseColor ; 16 17uniform bool b ; 18 19void main () 20{ 21vec4 color = BaseColor ; 22vec4 color2 ; 23 24color2 = otherColor ; 25 26if (c > d ) 27color += bigColor ; 28else 29color += smallColor ; 30 31if (color .z < minimum ) 32return ; 33 34color .z ++ ; 35 36if (color .z > threshhold ) 37discard ; 38 39color ++ ; 40 41// Two path, different rest 42if (color .w > threshhold2 ) { 43if (color .z > threshhold2 ) 44return ; 45else if (b ) 46color .z ++ ; 47else { 48if (color .x < minimum ) { 49discard ; 50 }else { 51color ++ ; 52 } 53 } 54 }else { 55if (b ) 56discard ; 57else 58return ; 59 } 60 61 62// // Two path, shared rest 63// if (color.w > threshhold2) { 64// if (color.z > threshhold2) 65// return; 66// else if (b) 67// color++; 68// else { 69// if (color.x < minimum) { 70// discard; 71// } else { 72// color++; 73// } 74// } 75// } else { 76// if (b) 77// discard; 78// else 79// return; 80// } 81 82 83// // One path 84// if (color.w > threshhold2) { 85// if (color.z > threshhold2) 86// return; 87// else { 88// if (color.x < minimum) { 89// discard; 90// } else { 91// color++; 92// } 93// } 94// } else { 95// if (b) 96// discard; 97// else 98// return; 99// } 100 101gl_FragColor = color * color2 ; 102}