ACMX Vulkan Shader Library
GLSL 4.50 shader effects for ACMX's Vulkan renderer
Loading...
Searching...
No Matches
rainbow_cd_curtain.frag File Reference

Vulkan fragment shader: rainbow cd curtain. More...

Go to the source code of this file.

Macros

#define iResolution   ext.u0.zw
#define time_f   ext.u2.y
#define value_alpha_r   ext.custom_uniforms[1].y

Functions

 layout (set=0, binding=1, std140) uniform SpriteExtended
 layout (location=0) in vec2 tc
 layout (set=0, binding=0) uniform sampler2D samp
float hash (float n)
 Evaluates hash for this shader effect.
vec2 random2 (vec2 st)
 Evaluates random2 for this shader effect.
vec2 smoothRandom2 (float t)
 Evaluates smoothRandom2 for this shader effect.
vec3 rainbow (float t, float seed)
 Evaluates rainbow for this shader effect.
float pingPong (float x, float length)
 Evaluates pingPong for this shader effect.
void main (void)
 Executes the fragment shader entry point.

Variables

 ext

Detailed Description

Vulkan fragment shader: rainbow cd curtain.

Definition in file rainbow_cd_curtain.frag.

Macro Definition Documentation

◆ iResolution

#define iResolution   ext.u0.zw

Definition at line 17 of file rainbow_cd_curtain.frag.

◆ time_f

#define time_f   ext.u2.y

Definition at line 18 of file rainbow_cd_curtain.frag.

◆ value_alpha_r

#define value_alpha_r   ext.custom_uniforms[1].y

Definition at line 19 of file rainbow_cd_curtain.frag.

Function Documentation

◆ hash()

float hash ( float n)

Evaluates hash for this shader effect.

Parameters
nInput value for the calculation.
Returns
Computed float value.

Definition at line 33 of file rainbow_cd_curtain.frag.

References hash(), and n().

◆ layout() [1/3]

layout ( location = 0)

References layout().

◆ layout() [2/3]

layout ( set = 0,
binding = 0 )

References layout().

◆ layout() [3/3]

layout ( set = 0,
binding = 1,
std140  )

Definition at line 7 of file rainbow_cd_curtain.frag.

References layout().

◆ main()

void main ( void )

Executes the fragment shader entry point.

Definition at line 90 of file rainbow_cd_curtain.frag.

References expand(), iResolution, main(), pingPong(), rainbow(), smoothRandom2(), time_f, value_alpha_r, and wave().

◆ pingPong()

float pingPong ( float x,
float length )

Evaluates pingPong for this shader effect.

Parameters
xInput value for the calculation.
lengthInput value for the calculation.
Returns
Computed float value.

Definition at line 82 of file rainbow_cd_curtain.frag.

References pingPong().

◆ rainbow()

vec3 rainbow ( float t,
float seed )

Evaluates rainbow for this shader effect.

Parameters
tInput value for the calculation.
seedInput value for the calculation.
Returns
Computed vec3 value.

Definition at line 68 of file rainbow_cd_curtain.frag.

References rainbow(), and seed.

◆ random2()

vec2 random2 ( vec2 st)

Evaluates random2 for this shader effect.

Parameters
stInput value for the calculation.
Returns
Computed vec2 value.

Definition at line 42 of file rainbow_cd_curtain.frag.

References random2().

◆ smoothRandom2()

vec2 smoothRandom2 ( float t)

Evaluates smoothRandom2 for this shader effect.

Parameters
tInput value for the calculation.
Returns
Computed vec2 value.

Definition at line 53 of file rainbow_cd_curtain.frag.

References rand1(), random2(), and smoothRandom2().

Variable Documentation

◆ ext

ext

Definition at line 16 of file rainbow_cd_curtain.frag.