feat: make audio visualizer FPS configurable
This commit is contained in:
parent
8f951946ea
commit
97455a862e
3 changed files with 35 additions and 1 deletions
|
|
@ -234,6 +234,7 @@ Singleton {
|
|||
property bool showMiniplayerCava: false
|
||||
property string visualizerType: "linear"
|
||||
property int volumeStep: 5
|
||||
property int cavaFps: 60
|
||||
}
|
||||
|
||||
// ui
|
||||
|
|
|
|||
|
|
@ -308,6 +308,39 @@ ColumnLayout {
|
|||
Settings.data.audio.visualizerType = key
|
||||
}
|
||||
}
|
||||
|
||||
NText {
|
||||
text: "Audio Visualizer FPS"
|
||||
font.pointSize: Style.fontSizeM * scaling
|
||||
font.weight: Style.fontWeightBold
|
||||
color: Color.mOnSurface
|
||||
}
|
||||
|
||||
ColumnLayout {
|
||||
spacing: Style.marginS * scaling
|
||||
Layout.fillWidth: true
|
||||
Layout.topMargin: Style.marginM * scaling
|
||||
|
||||
RowLayout {
|
||||
NSlider {
|
||||
Layout.fillWidth: true
|
||||
from: 0
|
||||
to: 360
|
||||
value: Settings.data.audio.cavaFps
|
||||
stepSize: 1
|
||||
onMoved: {
|
||||
Settings.data.audio.cavaFps = value
|
||||
}
|
||||
}
|
||||
|
||||
NText {
|
||||
text: Settings.data.audio.cavaFps + " FPS"
|
||||
Layout.alignment: Qt.AlignVCenter
|
||||
Layout.leftMargin: Style.marginS * scaling
|
||||
color: Color.mOnSurface
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -14,7 +14,7 @@ Singleton {
|
|||
property var config: ({
|
||||
"general": {
|
||||
"bars": barsCount,
|
||||
"framerate": 60,
|
||||
"framerate": Settings.data.audio.cavaFps,
|
||||
"autosens": 1,
|
||||
"sensitivity": 100,
|
||||
"lower_cutoff_freq": 50,
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue