[JSON-RPC] Possible to set "Volume Amplification"?
#1
Two parts to my question:

Is there a function to set the Volume Amplification and the Volume as it is done in the Audio - Settings: http://wiki.xbmc.org/index.php?title=Vid...e_settings

If there is, is there a way to make this volume amplification be used for both Video and Audio Add Ons?

Thanks,
Unifab
Reply
#2
You can set the volume with Application.SetVolume but you can't set the volume amplification. And as far as I know there's no volume amplification functionality for audio.
Always read the online manual (wiki), FAQ (wiki) and search the forum before posting.
Do not e-mail Team Kodi members directly asking for support. Read/follow the forum rules (wiki).
Please read the pages on troubleshooting (wiki) and bug reporting (wiki) before reporting issues.
Reply
#3
I think I found it. There is a <volumeamplification> entry under <defaultvideosettings> in the guisettings.xml file saved in %appdata%

I might be able to make it work that way since there is no JSON command for that.

Thanks,
Unifab
Reply
#4
(2014-07-22, 01:13)unifab Wrote: I think I found it. There is a <volumeamplification> entry under <defaultvideosettings> in the guisettings.xml file saved in %appdata%

I might be able to make it work that way since there is no JSON command for that.

Thanks,
Unifab

I don't think this will work. I believe when xbmc is running guisettings.xml resides in memory. So you can't externally write to the file while running xbmc.
Image Lunatixz - Kodi / Beta repository
Image PseudoTV - Forum | Website | Youtube | Help?
Reply
#5
You can but it's not picked up until the next restart of XBMC.
Always read the online manual (wiki), FAQ (wiki) and search the forum before posting.
Do not e-mail Team Kodi members directly asking for support. Read/follow the forum rules (wiki).
Please read the pages on troubleshooting (wiki) and bug reporting (wiki) before reporting issues.
Reply
#6
(2014-07-22, 06:38)Montellese Wrote: You can but it's not picked up until the next restart of XBMC.

I Stand corrected, I've noticed in the past changes made in guisettings.xml while xbmc was running was overridden when xbmc closed. Figured it was due to file being in memory then being dumped. Thanks for clarifying Smile
Image Lunatixz - Kodi / Beta repository
Image PseudoTV - Forum | Website | Youtube | Help?
Reply
#7
(2014-07-22, 06:46)Lunatixz Wrote:
(2014-07-22, 06:38)Montellese Wrote: You can but it's not picked up until the next restart of XBMC.

I Stand corrected, I've noticed in the past changes made in guisettings.xml while xbmc was running was overridden when xbmc closed. Figured it was due to file being in memory then being dumped. Thanks for clarifying Smile

You might actually be right. I forgot about the settings being written during shutdown.
Always read the online manual (wiki), FAQ (wiki) and search the forum before posting.
Do not e-mail Team Kodi members directly asking for support. Read/follow the forum rules (wiki).
Please read the pages on troubleshooting (wiki) and bug reporting (wiki) before reporting issues.
Reply
#8
(2014-07-22, 08:31)Montellese Wrote:
(2014-07-22, 06:46)Lunatixz Wrote:
(2014-07-22, 06:38)Montellese Wrote: You can but it's not picked up until the next restart of XBMC.

I Stand corrected, I've noticed in the past changes made in guisettings.xml while xbmc was running was overridden when xbmc closed. Figured it was due to file being in memory then being dumped. Thanks for clarifying Smile

You might actually be right. I forgot about the settings being written during shutdown.

They will only get overridden if the settings change during XMBC run. If we were to change the volumeamplification and click on the button that sets it as the new default, then guisettings.xml will be overriden with the new default. If the settings are not changed during run, then whatever is in the guisettings.xml file will be the new default settings.

Thanks,
Unifab
Reply
#9
(2014-07-19, 10:07)Montellese Wrote: You can set the volume with Application.SetVolume but you can't set the volume amplification. And as far as I know there's no volume amplification functionality for audio.

Has this changed with latest Kodi releases i.e. is there now a command to set volume amplification with json (or some other way) and have it in effect immediately?
Reply
#10
You can set volume amplification up and down by one unit issuing the command Input.ExecuteAction with action parameter "volampup" or "volampdown":

{"method":"Input.ExecuteAction","params":{"action":"volampup"}} --> raise volume amplification +1

{"method":"Input.ExecuteAction","params":{"action":"volampdown"}} --> lower volume amplification -1
Reply
#11
Thank you, works fine.

I have made a script assigned to a remote key that toggles between +15 and 0.

Earlier I was using these commands to do the adjustment:
("ActivateWindow(osdaudiosettings)")
("SetFocus(-79)")
("Action(Right)") --> repeated enought times...

Still, it would be even better if there was a direct value input method.

Btw. is it possible to somehow read the currently used volume amplification value?

My script is not able to detect the current value at playback start. So first button press adds +15, even when there already may be +15 amplification (amplification value is stored per file when you stop playback). I have "fixed" this by making the 0 position to go 30 steps down so the level gets reset to zero after second key press. It doesn't of course work correctly if you manually adjust amplification to a higher level than 30.
Reply
#12
AFAIK the volume amplification value cannot be retrieved via json Sad
Reply

Logout Mark Read Team Forum Stats Members Help
[JSON-RPC] Possible to set "Volume Amplification"?0