着色器技术飞跃
框架跟进
This commit is contained in:
@@ -1,11 +1,11 @@
|
||||
extern float t,w,h;
|
||||
vec4 effect(vec4 color,Image tex,vec2 tex_coords,vec2 scr_coords){
|
||||
float x=scr_coords.x/w;
|
||||
float y=scr_coords.y/h;
|
||||
uniform float phase;
|
||||
vec4 effect(vec4 color,sampler2D tex,vec2 texCoord,vec2 scrCoord){
|
||||
float x=scrCoord.x/love_ScreenSize.x;
|
||||
float y=scrCoord.y/love_ScreenSize.y;
|
||||
return vec4(
|
||||
.8-y*.8-.1*sin(t/6.26),
|
||||
.4+.1*sin(t/4.)*(y+2.)/(y+5.),
|
||||
abs(.7-x*1.4+y*.5*sin(t/16.)),
|
||||
.8-y*.8-.1*sin(phase/6.26),
|
||||
.4+.1*sin(phase/4.)*(y+2.)/(y+5.),
|
||||
abs(.7-x*1.4+y*.5*sin(phase/16.)),
|
||||
.4
|
||||
);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user