diff --git a/handheld/shaders/mgba/agb001.slang b/handheld/shaders/mgba/agb001.slang index 164ebf6..545131b 100644 --- a/handheld/shaders/mgba/agb001.slang +++ b/handheld/shaders/mgba/agb001.slang @@ -13,10 +13,10 @@ layout(std140, set = 0, binding = 0) uniform UBO { - mat4 MVP; - vec4 OutputSize; - vec4 OriginalSize; - vec4 SourceSize; + mat4 MVP; + vec4 OutputSize; + vec4 OriginalSize; + vec4 SourceSize; } global; #pragma stage vertex @@ -26,8 +26,8 @@ layout(location = 0) out vec2 vTexCoord; void main() { - gl_Position = global.MVP * Position; - vTexCoord = TexCoord; + gl_Position = global.MVP * Position; + vTexCoord = TexCoord; } #pragma stage fragment diff --git a/handheld/shaders/mgba/ags001-light.slang b/handheld/shaders/mgba/ags001-light.slang index 8292e59..e8b235f 100644 --- a/handheld/shaders/mgba/ags001-light.slang +++ b/handheld/shaders/mgba/ags001-light.slang @@ -13,19 +13,19 @@ layout(std140, set = 0, binding = 0) uniform UBO { - mat4 MVP; - vec4 OutputSize; - vec4 OriginalSize; - vec4 SourceSize; + mat4 MVP; + vec4 OutputSize; + vec4 OriginalSize; + vec4 SourceSize; } global; layout(push_constant) uniform Push { - float reflectionBrightness; - float reflectionDistanceX; - float reflectionDistanceY; - float lightBrightness; -} params; + float reflectionBrightness; + float reflectionDistanceX; + float reflectionDistanceY; + float lightBrightness; +}params; #pragma parameter reflectionBrightness "Reflection brightness" 0.07 0.0 1.0 0.01 #pragma parameter reflectionDistanceX "Reflection Distance X" 0.0 -1.0 1.0 0.005 @@ -39,8 +39,8 @@ layout(location = 0) out vec2 vTexCoord; void main() { - gl_Position = global.MVP * Position; - vTexCoord = TexCoord; + gl_Position = global.MVP * Position; + vTexCoord = TexCoord; } #pragma stage fragment @@ -54,7 +54,7 @@ const float coeff = 2.5; void main() { - vec2 reflectionDistance = vec2(params.reflectionDistanceX,params.reflectionDistanceY); + vec2 reflectionDistance = vec2(params.reflectionDistanceX,params.reflectionDistanceY); float sp = pow(speed, params.lightBrightness); float dc = pow(decay, -params.lightBrightness); float s = (sp - dc) / (sp + dc); @@ -69,6 +69,6 @@ void main() vec4 reflection = texture(Source, vTexCoord - reflectionDistance); color.rgb += reflection.rgb * params.reflectionBrightness; color.a = 1.0; - FragColor = color; + FragColor = color; } diff --git a/handheld/shaders/mgba/ags001.slang b/handheld/shaders/mgba/ags001.slang index bcca6ea..06d3b70 100644 --- a/handheld/shaders/mgba/ags001.slang +++ b/handheld/shaders/mgba/ags001.slang @@ -13,10 +13,10 @@ layout(std140, set = 0, binding = 0) uniform UBO { - mat4 MVP; - vec4 OutputSize; - vec4 OriginalSize; - vec4 SourceSize; + mat4 MVP; + vec4 OutputSize; + vec4 OriginalSize; + vec4 SourceSize; } global; #pragma stage vertex @@ -26,8 +26,8 @@ layout(location = 0) out vec2 vTexCoord; void main() { - gl_Position = global.MVP * Position; - vTexCoord = TexCoord; + gl_Position = global.MVP * Position; + vTexCoord = TexCoord; } #pragma stage fragment