diff --git a/kwin/build.sh b/kwin/build.sh index 1916e8b..d03034f 100755 --- a/kwin/build.sh +++ b/kwin/build.sh @@ -123,16 +123,12 @@ generate() { } # Now run the above method for all supported effects. - -# The apparition effect is disabled for now. I have not yet found a way to upscale the -# window canvas during the animation. -#generate "apparition" "[BMW] Apparition" "This effect hides your windows by violently sucking them into the void of magic" - generate "energize-a" "Energize A [Burn-My-Windows]" "Beam your windows away" generate "energize-b" "Energize B [Burn-My-Windows]" "Using different transporter technology results in an alternative visual effect" generate "doom" "Doom [Burn-My-Windows]" "Melt your windows" generate "fire" "Fire [Burn-My-Windows]" "The classic effect inspired by Compiz" generate "glide" "Glide [Burn-My-Windows]" "Fade the window to transparency with subtle 3D effects" +generate "glitch" "Glitch [Burn-My-Windows]" "This effect applies some intentional graphics issues to your windows" generate "hexagon" "Hexagon [Burn-My-Windows]" "With glowing lines and hexagon-shaped tiles, this effect looks very sci-fi" generate "incinerate" "Incinerate [Burn-My-Windows]" "A less snappy but definitely more fancy take on the fire effect" generate "pixelate" "Pixelate [Burn-My-Windows]" "Pixelate the window and randomly hide the pixels" diff --git a/kwin/glitch/config.ui b/kwin/glitch/config.ui new file mode 100755 index 0000000..69664ab --- /dev/null +++ b/kwin/glitch/config.ui @@ -0,0 +1,100 @@ + + + + + + BMWConfigForm + + + + 0 + 0 + 562 + 365 + + + + + + + Duration: + + + Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter + + + + + + + Color: + + + Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter + + + kcfg_Color + + + + + + + true + + + + + + + Scale: + + + Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter + + + kcfg_Color + + + + + + + 0.100000000000000 + + + 10.000000000000000 + + + + + + + milliseconds + + + 100 + + + 9999 + + + 100 + + + + + + + + KColorButton + QPushButton +
kcolorbutton.h
+
+
+ + +
\ No newline at end of file diff --git a/kwin/glitch/main.xml b/kwin/glitch/main.xml new file mode 100755 index 0000000..31f1d35 --- /dev/null +++ b/kwin/glitch/main.xml @@ -0,0 +1,28 @@ + + + + + + + + + 2000 + + + 1 + + + 2 + + + 2 + + + #64A0FF + + + \ No newline at end of file diff --git a/kwin/glitch/onAnimationBegin.js b/kwin/glitch/onAnimationBegin.js new file mode 100644 index 0000000..53dc727 --- /dev/null +++ b/kwin/glitch/onAnimationBegin.js @@ -0,0 +1,7 @@ +// SPDX-FileCopyrightText: Simon Schneegans +// SPDX-License-Identifier: GPL-3.0-or-later + +// This part is automatically included in the effect's source during the build process. +// The code below is called whenever a window is closed or opened. + +effect.setUniform(this.shader, 'uSeed', Math.random()); diff --git a/kwin/glitch/onSettingsChanged.js b/kwin/glitch/onSettingsChanged.js new file mode 100644 index 0000000..03c946f --- /dev/null +++ b/kwin/glitch/onSettingsChanged.js @@ -0,0 +1,12 @@ +// SPDX-FileCopyrightText: Simon Schneegans +// SPDX-License-Identifier: GPL-3.0-or-later + +// This part is automatically included in the effect's source during the build process. +// The code below is called whenever the user changes something in the configuration of +// the effect. + +effect.setUniform(this.shader, 'uDuration', this.duration * 0.001); +effect.setUniform(this.shader, 'uScale', effect.readConfig('Scale', 1.0)); +effect.setUniform(this.shader, 'uStrength', effect.readConfig('Strength', 1.0)); +effect.setUniform(this.shader, 'uSpeed', effect.readConfig('Speed', 1.0)); +effect.setUniform(this.shader, 'uColor', this.readRGBConfig('Color')); \ No newline at end of file