#define PI 3.14 extern float yresolution; vec4 effect(vec4 color,Image texture,vec2 texture_coords,vec2 screen_coords){ //Iterate through the occluder map's y-axis. for(float y=0.;y.1)return vec4(vec3(y/yresolution),1.);//碰撞检测,像素透明度>.1即透光 } return vec4(vec3(1),1.);//返回最远距离1 }