summaryrefslogtreecommitdiff
path: root/raveos-plasma-theme/theme-data/sddm/sddm-rave-theme/Components/ParticleOverlay.qml
diff options
context:
space:
mode:
authorNippy <nippy@rp1.hu>2026-07-03 13:24:36 +0200
committerNippy <nippy@rp1.hu>2026-07-03 13:24:36 +0200
commit7de9210d7806e34d47803c361d7a95e29e877de3 (patch)
treee74edd19540e43e3c2926dd37b8151603d809294 /raveos-plasma-theme/theme-data/sddm/sddm-rave-theme/Components/ParticleOverlay.qml
parentaf5dd5ec4bf911af75912f3cea6f53d5a8676f12 (diff)
downloadRaveOS-PKGBUILD-7de9210d7806e34d47803c361d7a95e29e877de3.tar.gz
RaveOS-PKGBUILD-7de9210d7806e34d47803c361d7a95e29e877de3.zip
new sddm
Diffstat (limited to 'raveos-plasma-theme/theme-data/sddm/sddm-rave-theme/Components/ParticleOverlay.qml')
-rw-r--r--raveos-plasma-theme/theme-data/sddm/sddm-rave-theme/Components/ParticleOverlay.qml90
1 files changed, 0 insertions, 90 deletions
diff --git a/raveos-plasma-theme/theme-data/sddm/sddm-rave-theme/Components/ParticleOverlay.qml b/raveos-plasma-theme/theme-data/sddm/sddm-rave-theme/Components/ParticleOverlay.qml
deleted file mode 100644
index 6fa02f9..0000000
--- a/raveos-plasma-theme/theme-data/sddm/sddm-rave-theme/Components/ParticleOverlay.qml
+++ /dev/null
@@ -1,90 +0,0 @@
-// Config created by Keyitdev https://git.rp1.hu/gabeszm/sddm-rave-theme
-// Copyright (C) 2022-2025 Keyitdev
-// Distributed under the GPLv3+ License https://www.gnu.org/licenses/gpl-3.0.html
-
-import QtQuick 2.15
-
-Canvas {
- id: particleCanvas
-
- anchors.fill: parent
-
- property int particleCount: 55
- property var particles: []
- property real time: 0
-
- function initParticles() {
- var arr = []
- for (var i = 0; i < particleCount; i++) {
- arr.push({
- x: Math.random() * width,
- y: Math.random() * height,
- vx: (Math.random() - 0.5) * 0.35,
- vy: (Math.random() - 0.5) * 0.35,
- baseR: Math.random() * 2.0 + 0.8,
- hue: Math.random() * 360,
- hueSpeed: (Math.random() - 0.5) * 0.4,
- phase: Math.random() * Math.PI * 2,
- opacity: Math.random() * 0.45 + 0.15,
- glowR: Math.random() * 18 + 8
- })
- }
- particles = arr
- }
-
- onPaint: {
- var ctx = getContext("2d")
- ctx.clearRect(0, 0, width, height)
-
- for (var i = 0; i < particles.length; i++) {
- var p = particles[i]
- var r = p.baseR * (0.75 + 0.25 * Math.sin(p.phase + time * 2.2))
-
- // Glow halo
- var grd = ctx.createRadialGradient(p.x, p.y, 0, p.x, p.y, p.glowR)
- grd.addColorStop(0, "hsla(" + p.hue + ",100%,72%," + (p.opacity * 0.55) + ")")
- grd.addColorStop(1, "hsla(" + p.hue + ",100%,72%,0)")
- ctx.beginPath()
- ctx.arc(p.x, p.y, p.glowR, 0, Math.PI * 2)
- ctx.fillStyle = grd
- ctx.fill()
-
- // Core dot
- ctx.beginPath()
- ctx.arc(p.x, p.y, r, 0, Math.PI * 2)
- ctx.fillStyle = "hsla(" + p.hue + ",100%,88%," + p.opacity + ")"
- ctx.fill()
- }
- }
-
- Timer {
- interval: 16
- repeat: true
- running: true
- onTriggered: {
- particleCanvas.time += 0.016
- var pts = particleCanvas.particles
- var W = particleCanvas.width
- var H = particleCanvas.height
- var t = particleCanvas.time
- for (var i = 0; i < pts.length; i++) {
- var p = pts[i]
- p.x += p.vx + Math.sin(t * 0.9 + p.phase) * 0.28
- p.y += p.vy + Math.cos(t * 0.7 + p.phase) * 0.28
- p.hue += p.hueSpeed
- p.phase += 0.008
- var margin = p.glowR
- if (p.x < -margin) p.x = W + margin
- if (p.x > W + margin) p.x = -margin
- if (p.y < -margin) p.y = H + margin
- if (p.y > H + margin) p.y = -margin
- }
- particleCanvas.requestPaint()
- }
- }
-
- Component.onCompleted: {
- // kis késleltetés hogy a méret biztosan kész legyen
- Qt.callLater(initParticles)
- }
-}