Set volume globally
Unsolved
QML and Qt Quick
-
Hi,
is it possible to globally set volume of audio output of my application?I have several QSoundEffect sounds in my QML application. I thought about the possibility to set some global context variable (double with 0.0 to 1.0 value) to QML and then use it in my sounds:
SoundEffect { volume: 0.25 * myGlobalVolume }
However, is there a better way to achieve this?
-
Hi,
Do you mean something like a VolumeController object that has a volume property ? You could set it using setContextProperty, then it would be available to your effects.
Hope it helps.