Command line control of plugin parameters
I am looking for a way to change the parameters of a plugin via the command line. Specifically, the speed-pitch plugin. What I have in mind is something like this:
audtool plugin-parameter speed-pitch speed 1.15
audtool plugin-parameter speed-pitch pitch 0.891
When I send it the speed is updated and if the plugin is enabled then it has immediate effect.
#2 Updated by Chris Laurie 7 months ago
OK I can think of an alternative:
A command line option that forces a reload of the config information. That way I can update the config file myself, and then signal audacious that the config settings has changed and that it must reload the information. It seems audacious reads it once on load and only saves it back when the application closes.
#3 Updated by John Lindgren 7 months ago
- Description updated (diff)
- Category set to audtool
- Status changed from New to Closed
- Target version set to 3.10
- % Done changed from 0 to 100
Five years ago, I would have said the same thing as Michael, but the infrastructure has been improved since then, so this is actually not hard to implement. It won't work for every plugin, but many of the newer ones (including Speed and Pitch) have been designed to be less coupled to their settings GUI. So I went ahead and implemented this, but I'll just repeat what I said in the manual page:
--config-get [section:]name Print the value of a configuration setting. Any use of this command is entirely unsupported. How to find the section and name of a given setting is left as an exercise for the reader. --config-set [section:]name value Change the value of a configuration setting. This command is unsupported and dangerous. It might have unexpected side effects (such as crashing Audacious), or it might have no effect at all. Use it at your own risk!
That said, you might find the following useful (if you build the latest Audacious from Git):
audtool config-set speed-pitch:speed 1.15 audtool config-set speed-pitch:pitch 0.891
#5 Updated by Michael Schwendt 7 months ago
Well, with fairness in mind, only making it work for all plugins would invalidate what I've written above. I've had $subject in mind, not only a single plugin. Many plugins won't pass on changed configuration parameters to their backends "magically" and would need to be changed.
#6 Updated by Chris Laurie 7 months ago
Apologies for the late response but thank very much you for this enhancement!
I am having some trouble with the windows build so I noticed there was a new windows build (3.9a 2017-09-12) released for another issue. I tried that one and it seems that this functionality is not in that build. If that was intentional, then please ignore this update.