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

Vulkan fragment shader: gpt trip. More...

Go to the source code of this file.

Macros

#define iResolution   ext.u0.zw
#define time_f   ext.u2.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 lum (vec3 c)
 Evaluates lum for this shader effect.
float hash (vec2 p)
 Evaluates hash for this shader effect.
float noise (vec2 p)
 Evaluates noise for this shader effect.
vec3 rgb2hsv (vec3 c)
 Evaluates rgb2hsv for this shader effect.
vec3 hsv2rgb (vec3 c)
 Evaluates hsv2rgb for this shader effect.
vec2 warp (vec2 uv)
 Evaluates warp for this shader effect.
float edgeSobel (vec2 uv, vec2 px)
 Evaluates edgeSobel for this shader effect.
void main ()
 Executes the fragment shader entry point.

Variables

 ext

Detailed Description

Vulkan fragment shader: gpt trip.

Definition in file gpt_trip.frag.

Macro Definition Documentation

◆ iResolution

#define iResolution   ext.u0.zw

Definition at line 17 of file gpt_trip.frag.

◆ time_f

#define time_f   ext.u2.y

Definition at line 18 of file gpt_trip.frag.

Function Documentation

◆ edgeSobel()

float edgeSobel ( vec2 uv,
vec2 px )

Evaluates edgeSobel for this shader effect.

Parameters
uvInput value for the calculation.
pxInput value for the calculation.
Returns
Computed float value.

Definition at line 113 of file gpt_trip.frag.

References edgeSobel(), and lum().

Referenced by edgeSobel(), and main().

◆ hash()

float hash ( vec2 p)

Evaluates hash for this shader effect.

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

Definition at line 40 of file gpt_trip.frag.

References hash().

◆ hsv2rgb()

vec3 hsv2rgb ( vec3 c)

Evaluates hsv2rgb for this shader effect.

Parameters
cInput value for the calculation.
Returns
Computed vec3 value.

Definition at line 79 of file gpt_trip.frag.

References hsv2rgb().

◆ 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 gpt_trip.frag.

References layout().

◆ lum()

float lum ( vec3 c)

Evaluates lum for this shader effect.

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

Definition at line 31 of file gpt_trip.frag.

References lum().

◆ main()

void main ( void )

Executes the fragment shader entry point.

Definition at line 132 of file gpt_trip.frag.

References edgeSobel(), hsv2rgb(), iResolution, lum(), main(), rgb2hsv(), s2(), s3, time_f, and warp().

◆ noise()

float noise ( vec2 p)

Evaluates noise for this shader effect.

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

Definition at line 49 of file gpt_trip.frag.

References hash(), and noise().

◆ rgb2hsv()

vec3 rgb2hsv ( vec3 c)

Evaluates rgb2hsv for this shader effect.

Parameters
cInput value for the calculation.
Returns
Computed vec3 value.

Definition at line 65 of file gpt_trip.frag.

References rgb2hsv().

Referenced by main(), main(), and rgb2hsv().

◆ warp()

vec2 warp ( vec2 uv)

Evaluates warp for this shader effect.

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

Definition at line 90 of file gpt_trip.frag.

References n2(), noise(), time_f, and warp().

Variable Documentation

◆ ext

ext

Definition at line 16 of file gpt_trip.frag.