From 70b7213af79bff53d6ef843ad4207eeb06aef562 Mon Sep 17 00:00:00 2001 From: Doridian Date: Sun, 8 Sep 2024 11:11:37 -0700 Subject: [PATCH] Update shaders and shader compilation --- panon/effect/build_shader_source.py | 2 +- plasmoid/contents/shaders/gldft.fsh | 6 +++--- plasmoid/contents/shaders/wave-buffer.fsh | 6 +++--- 3 files changed, 7 insertions(+), 7 deletions(-) diff --git a/panon/effect/build_shader_source.py b/panon/effect/build_shader_source.py index 1709c0e..7b4ea5d 100644 --- a/panon/effect/build_shader_source.py +++ b/panon/effect/build_shader_source.py @@ -108,7 +108,7 @@ def build_qsb(shader_source: str) -> str: raise Exception("qsb not found") qsb, qsb_path = tempfile.mkstemp(dir=tmp_dir, suffix='.qsb') - subprocess.run([qsb_bin_path, '--qt6', frag_path, '-o', qsb_path], check=True) + subprocess.run([qsb_bin_path, '--glsl', '150', frag_path, '-o', qsb_path], check=True) os.close(qsb) return qsb_path diff --git a/plasmoid/contents/shaders/gldft.fsh b/plasmoid/contents/shaders/gldft.fsh index f2c91c2..598a63d 100644 --- a/plasmoid/contents/shaders/gldft.fsh +++ b/plasmoid/contents/shaders/gldft.fsh @@ -1,7 +1,7 @@ -#version 130 +#version 440 -out vec4 out_Color; -in mediump vec2 qt_TexCoord0; +layout(location = 0) in vec2 qt_TexCoord0; +layout(location = 0) out vec4 out_Color; uniform sampler2D waveBuffer; diff --git a/plasmoid/contents/shaders/wave-buffer.fsh b/plasmoid/contents/shaders/wave-buffer.fsh index 22e4803..a6cd8b9 100644 --- a/plasmoid/contents/shaders/wave-buffer.fsh +++ b/plasmoid/contents/shaders/wave-buffer.fsh @@ -1,7 +1,7 @@ -#version 130 +#version 440 -out vec4 out_Color; -in mediump vec2 qt_TexCoord0; +layout(location = 0) in vec2 qt_TexCoord0; +layout(location = 0) out vec4 out_Color; uniform sampler2D newWave; uniform sampler2D waveBuffer;