Merge pull request #132 from ThatOneCalculator/feat/cava-fps-config
feat: make audio visualizer FPS configurable
This commit is contained in:
commit
ecc43f7f1e
4 changed files with 53 additions and 1 deletions
|
|
@ -236,6 +236,7 @@ Singleton {
|
||||||
property bool showMiniplayerCava: false
|
property bool showMiniplayerCava: false
|
||||||
property string visualizerType: "linear"
|
property string visualizerType: "linear"
|
||||||
property int volumeStep: 5
|
property int volumeStep: 5
|
||||||
|
property int cavaFrameRate: 60
|
||||||
}
|
}
|
||||||
|
|
||||||
// ui
|
// ui
|
||||||
|
|
|
||||||
|
|
@ -308,6 +308,45 @@ ColumnLayout {
|
||||||
Settings.data.audio.visualizerType = key
|
Settings.data.audio.visualizerType = key
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
NComboBox {
|
||||||
|
label: "Frame Rate"
|
||||||
|
description: "Target frame rate for audio visualizer. (default: 60)"
|
||||||
|
model: ListModel {
|
||||||
|
ListElement {
|
||||||
|
key: "30"
|
||||||
|
name: "30 FPS"
|
||||||
|
}
|
||||||
|
ListElement {
|
||||||
|
key: "60"
|
||||||
|
name: "60 FPS"
|
||||||
|
}
|
||||||
|
ListElement {
|
||||||
|
key: "100"
|
||||||
|
name: "100 FPS"
|
||||||
|
}
|
||||||
|
ListElement {
|
||||||
|
key: "120"
|
||||||
|
name: "120 FPS"
|
||||||
|
}
|
||||||
|
ListElement {
|
||||||
|
key: "144"
|
||||||
|
name: "144 FPS"
|
||||||
|
}
|
||||||
|
ListElement {
|
||||||
|
key: "165"
|
||||||
|
name: "165 FPS"
|
||||||
|
}
|
||||||
|
ListElement {
|
||||||
|
key: "240"
|
||||||
|
name: "240 FPS"
|
||||||
|
}
|
||||||
|
}
|
||||||
|
currentKey: Settings.data.audio.cavaFrameRate
|
||||||
|
onSelected: key => {
|
||||||
|
Settings.data.audio.cavaFrameRate = key
|
||||||
|
}
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -125,10 +125,22 @@ ColumnLayout {
|
||||||
key: "60"
|
key: "60"
|
||||||
name: "60 FPS"
|
name: "60 FPS"
|
||||||
}
|
}
|
||||||
|
ListElement {
|
||||||
|
key: "100"
|
||||||
|
name: "100 FPS"
|
||||||
|
}
|
||||||
ListElement {
|
ListElement {
|
||||||
key: "120"
|
key: "120"
|
||||||
name: "120 FPS"
|
name: "120 FPS"
|
||||||
}
|
}
|
||||||
|
ListElement {
|
||||||
|
key: "144"
|
||||||
|
name: "144 FPS"
|
||||||
|
}
|
||||||
|
ListElement {
|
||||||
|
key: "165"
|
||||||
|
name: "165 FPS"
|
||||||
|
}
|
||||||
ListElement {
|
ListElement {
|
||||||
key: "240"
|
key: "240"
|
||||||
name: "240 FPS"
|
name: "240 FPS"
|
||||||
|
|
|
||||||
|
|
@ -14,7 +14,7 @@ Singleton {
|
||||||
property var config: ({
|
property var config: ({
|
||||||
"general": {
|
"general": {
|
||||||
"bars": barsCount,
|
"bars": barsCount,
|
||||||
"framerate": 60,
|
"framerate": Settings.data.audio.cavaFrameRate,
|
||||||
"autosens": 1,
|
"autosens": 1,
|
||||||
"sensitivity": 100,
|
"sensitivity": 100,
|
||||||
"lower_cutoff_freq": 50,
|
"lower_cutoff_freq": 50,
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue