43 lines
461 B
Plaintext
43 lines
461 B
Plaintext
|
#cull back
|
||
|
|
||
|
@vs vs
|
||
|
in vec3 a_pos;
|
||
|
in vec2 a_uv;
|
||
|
|
||
|
out vec2 uv;
|
||
|
|
||
|
void main()
|
||
|
{
|
||
|
vec3 pos = a_pos;
|
||
|
pos -= 0.5;
|
||
|
pos *= 2;
|
||
|
uv = a_uv;
|
||
|
gl_Position = vec4(pos.xy, 0, 1.0);
|
||
|
}
|
||
|
@end
|
||
|
|
||
|
@fs fs
|
||
|
in vec2 uv;
|
||
|
|
||
|
out vec4 color;
|
||
|
|
||
|
#define PI 3.141592
|
||
|
|
||
|
@image_sample_type diffuse unfilterable_float
|
||
|
texture2D diffuse;
|
||
|
@sampler_type smp nonfiltering
|
||
|
sampler smp;
|
||
|
|
||
|
uniform vec2 mouse;
|
||
|
uniform float time;
|
||
|
|
||
|
@include_block frag
|
||
|
|
||
|
void main()
|
||
|
{
|
||
|
frag();
|
||
|
}
|
||
|
@end
|
||
|
|
||
|
@program p vs fs
|