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

Vulkan fragment shader: hallu code abyssal opaline. More...

Go to the source code of this file.

Macros

#define amp_high   ext.audio_bands.z
#define amp_low   ext.audio_bands.x
#define amp_mid   ext.audio_bands.y
#define amp_peak   ext.u2.w
#define amp_smooth   ext.u3.w
#define iMouse   ext.mouse
#define iResolution   ext.u0.zw
#define time_f   ext.u2.y

Functions

 layout (set=0, binding=1, std140) uniform SpriteExtended
 layout (set=0, binding=0) uniform sampler2D samp
 layout (location=0) out vec4 color
mat2 rot (float a)
 Evaluates rot for this shader effect.
vec2 wrapUV (vec2 uv)
 Evaluates wrapUV for this shader effect.
vec3 sampleMirror (vec2 uv)
 Evaluates sampleMirror for this shader effect.
float hash21 (vec2 p)
 Evaluates hash21 for this shader effect.
float noise (vec2 p)
 Evaluates noise for this shader effect.
float fbm (vec2 p)
 Evaluates fbm for this shader effect.
vec2 curlField (vec2 p, float t)
 Evaluates curlField for this shader effect.
vec3 opalPalette (float t)
 Evaluates opalPalette for this shader effect.
vec3 angularOpal (float angle, float phase)
 Evaluates angularOpal for this shader effect.
float gyroid (vec3 p)
 Evaluates gyroid for this shader effect.
vec3 abyssalOpal (vec2 uv, vec2 center, float t, vec3 audio)
 Evaluates abyssalOpal for this shader effect.
void main ()
 Executes the fragment shader entry point.

Variables

 ext
const float TAU = 6.28318530718
const float iBrightness = 1.02
const float iContrast = 1.16
const float iSaturation = 1.36

Detailed Description

Vulkan fragment shader: hallu code abyssal opaline.

Definition in file hallu_code_abyssal_opaline.frag.

Macro Definition Documentation

◆ amp_high

#define amp_high   ext.audio_bands.z

Definition at line 17 of file hallu_code_abyssal_opaline.frag.

◆ amp_low

#define amp_low   ext.audio_bands.x

Definition at line 18 of file hallu_code_abyssal_opaline.frag.

◆ amp_mid

#define amp_mid   ext.audio_bands.y

Definition at line 19 of file hallu_code_abyssal_opaline.frag.

◆ amp_peak

#define amp_peak   ext.u2.w

Definition at line 20 of file hallu_code_abyssal_opaline.frag.

◆ amp_smooth

#define amp_smooth   ext.u3.w

Definition at line 21 of file hallu_code_abyssal_opaline.frag.

◆ iMouse

#define iMouse   ext.mouse

Definition at line 22 of file hallu_code_abyssal_opaline.frag.

◆ iResolution

#define iResolution   ext.u0.zw

Definition at line 23 of file hallu_code_abyssal_opaline.frag.

◆ time_f

#define time_f   ext.u2.y

Definition at line 24 of file hallu_code_abyssal_opaline.frag.

Function Documentation

◆ abyssalOpal()

vec3 abyssalOpal ( vec2 uv,
vec2 center,
float t,
vec3 audio )

Evaluates abyssalOpal for this shader effect.

Parameters
uvInput value for the calculation.
centerInput value for the calculation.
tInput value for the calculation.
audioInput value for the calculation.
Returns
Computed vec3 value.

Definition at line 175 of file hallu_code_abyssal_opaline.frag.

References abyssalOpal(), angularOpal(), caustic(), curl(), curlField(), fbm(), gyroid(), iResolution, lens(), opal(), opalPalette(), pearl(), rot(), sampleMirror(), twist(), and wave().

Referenced by abyssalOpal(), and main().

◆ angularOpal()

vec3 angularOpal ( float angle,
float phase )

Evaluates angularOpal for this shader effect.

Parameters
angleInput value for the calculation.
phaseInput value for the calculation.
Returns
Computed vec3 value.

Definition at line 152 of file hallu_code_abyssal_opaline.frag.

References angularOpal(), harmonic(), and TAU.

Referenced by abyssalOpal(), and angularOpal().

◆ curlField()

vec2 curlField ( vec2 p,
float t )

Evaluates curlField for this shader effect.

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

Definition at line 123 of file hallu_code_abyssal_opaline.frag.

References curlField(), fbm(), and n2().

Referenced by abyssalOpal(), and curlField().

◆ fbm()

float fbm ( vec2 p)

Evaluates fbm for this shader effect.

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

Definition at line 105 of file hallu_code_abyssal_opaline.frag.

References fbm(), and noise().

◆ gyroid()

float gyroid ( vec3 p)

Evaluates gyroid for this shader effect.

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

Definition at line 163 of file hallu_code_abyssal_opaline.frag.

References gyroid().

Referenced by abyssalOpal(), and gyroid().

◆ hash21()

float hash21 ( vec2 p)

Evaluates hash21 for this shader effect.

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

Definition at line 81 of file hallu_code_abyssal_opaline.frag.

References hash21().

◆ layout() [1/3]

layout ( location = 0)

References layout().

◆ layout() [2/3]

layout ( set = 0,
binding = 0 )

References layout(), and spectrum().

◆ layout() [3/3]

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

Definition at line 7 of file hallu_code_abyssal_opaline.frag.

References layout().

◆ main()

void main ( void )

Executes the fragment shader entry point.

Definition at line 248 of file hallu_code_abyssal_opaline.frag.

References abyssalOpal(), amp_high, amp_low, amp_mid, amp_peak, amp_smooth, beat(), iBrightness, iContrast, iMouse, iResolution, iSaturation, luma(), main(), spectrum(), and time_f.

◆ noise()

float noise ( vec2 p)

Evaluates noise for this shader effect.

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

Definition at line 92 of file hallu_code_abyssal_opaline.frag.

References hash21(), and noise().

◆ opalPalette()

vec3 opalPalette ( float t)

Evaluates opalPalette for this shader effect.

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

Definition at line 137 of file hallu_code_abyssal_opaline.frag.

References opalPalette(), and TAU.

Referenced by abyssalOpal(), and opalPalette().

◆ rot()

mat2 rot ( float a)

Evaluates rot for this shader effect.

Parameters
aInput value for the calculation.
Returns
Computed mat2 value.

Definition at line 51 of file hallu_code_abyssal_opaline.frag.

References rot().

◆ sampleMirror()

vec3 sampleMirror ( vec2 uv)

Evaluates sampleMirror for this shader effect.

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

Definition at line 70 of file hallu_code_abyssal_opaline.frag.

References sampleMirror(), and wrapUV().

Referenced by abyssalOpal(), main(), sampleMirror(), and xenolith().

◆ wrapUV()

vec2 wrapUV ( vec2 uv)

Evaluates wrapUV for this shader effect.

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

Definition at line 61 of file hallu_code_abyssal_opaline.frag.

References wrapUV().

Variable Documentation

◆ ext

ext

Definition at line 16 of file hallu_code_abyssal_opaline.frag.

◆ iBrightness

const float iBrightness = 1.02

Definition at line 42 of file hallu_code_abyssal_opaline.frag.

◆ iContrast

const float iContrast = 1.16

Definition at line 43 of file hallu_code_abyssal_opaline.frag.

◆ iSaturation

const float iSaturation = 1.36

Definition at line 44 of file hallu_code_abyssal_opaline.frag.

◆ TAU

const float TAU = 6.28318530718

Definition at line 41 of file hallu_code_abyssal_opaline.frag.