ACMX Vulkan Shader Library
GLSL 4.50 shader effects for ACMX's Vulkan renderer
Loading...
Searching...
No Matches
glitch_jump.frag
Go to the documentation of this file.
1#version 450
2
3/**
4 * @file glitch_jump.frag
5 * @brief Vulkan fragment shader: glitch jump.
6 */
7layout(set = 0, binding = 1, std140) uniform SpriteExtended {
8 vec4 mouse;
9 vec4 u0;
10 vec4 u1;
11 vec4 u2;
12 vec4 u3;
13 vec4 custom_uniforms[16];
14 vec4 audio_bands;
15 vec4 audio_history;
17#define iResolution ext.u0.zw
18#define time_f ext.u2.y
19#define value_alpha_b ext.custom_uniforms[1].w
20#define value_alpha_g ext.custom_uniforms[1].z
21#define value_alpha_r ext.custom_uniforms[1].y
22
23layout(location = 0) out vec4 color;
24layout(location = 0) in vec2 tc;
25layout(set = 0, binding = 0) uniform sampler2D samp;
26
27
28
29
30/**
31 * @brief Executes the fragment shader entry point.
32 */
33void main(void) {
34 vec2 pos = tc;
35 float time_t = mod(time_f, 10.0);
36 pos = pos+sin(value_alpha_r * time_t);
37 color = texture(samp, pos);
38}
layout(set=0, binding=1, std140) uniform SpriteExtended
Definition 3high.frag:7
ext
Definition 3high.frag:16
void main(void)
Executes the fragment shader entry point.
Definition 3high.frag:47
#define time_f
Definition 3high.frag:19
#define value_alpha_r