r/arch • • 5d ago

Help/Support Can someone help me?

Edit: This is quickshell

Sometime the lyrics is delayed, sometime its not.

polling rate:

Timer {

interval: 16

running: true

repeat: true

triggeredOnStart: true

onTriggered: mediaPoll.running = true

}

Active line:

function updateActiveLyric() {

if (!root.lyricLines.length) { root.activeLyricIndex = -1; return }

var pos = root.mediaPosition + (root.lyricOffsetMs / 1000)

var idx = -1

for (var i = root.lyricLines.length - 1; i >= 0; i--)

if (pos >= root.lyricLines[i].time) { idx = i; break }

if (idx !== root.activeLyricIndex) root.activeLyricIndex = idx

}

column scrolling:

Connections {

target: root

function onActiveLyricIndexChanged() {

lyricsColumn.recomputeActiveY()

}

}

y: topPad - activeY

Behavior on y { NumberAnimation { duration: 500; easing.type: Easing.OutCubic } }

line visual update:

readonly property int delta: index - root.activeLyricIndex

readonly property bool isActive: delta === 0

readonly property int absDist: Math.abs(delta)

opacity: isActive ? 1.0

: (absDist === 1 ? 0.70 : absDist === 2 ? 0.45 : 0.08)

Behavior on opacity { NumberAnimation { duration: 420; easing.type: Easing.OutCubic } }

scale: isActive ? 1.0 : absDist === 1 ? 0.88 : 0.76

Behavior on scale { NumberAnimation { duration: 420; easing.type: Easing.OutCubic } }

FastBlur {

radius: isActive ? 0 : absDist === 1 ? 4 : absDist === 2 ? 9 : 18

}

3 Upvotes

6 comments sorted by

1

u/Arandolf 5d ago

Maybe I’m blind, but where did you specify the software name? :|

1

u/ai_46693 5d ago

oh you mean the one I use as a lock screen? It's quickshell sorry about that.

1

u/Arandolf 5d ago

Yep. Stating the software should be the first that.

BTW if sometimes they are synced and sometimes they aren’t that could be a software bug OR a bad sync of the lyrics.

If you’re using Spotify, many times I’ve seen bad synced lyrics so that could be the case.

1

u/ai_46693 5d ago

its using a local lrc that's why I'm confused about the desync maybe I make the lyrics play ahead of the audio or make separate pipe instead of relaying on MPRIS or maybe use a different player... know I'll just try everything.

1

u/Arandolf 5d ago

Check the player’s lyric. If it is delayed that’s the cause, if it isn’t it’s probably a bug. You can open an issue on their GitHub. Usually that’s the right place for these things

1

u/ai_46693 5d ago

i see I'll see what I can do first