-
Notifications
You must be signed in to change notification settings - Fork 10
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Calls result in PlatformExceptions #46
Comments
Hi, can you provide more context? Like what sound output device you have selected? |
Hi |
It seems your monitor doesn't support volume control. Right now the plugin can only access the default audio output device. If you want to control another audio device, like switching from monitor to macbook speaker, you have to do it from OS settings. A better approach would be controlling a specific output device through its device id. But it would take some times to implement on different desktop platforms. |
I wasn't looking to control the output device only react to it changing and knowing its capabilities. Currently I only know there is no volume control when I ask for the current volume and an exception is thrown. It would be nicer if calling getVolume reported it wasn't available rather than getting an exception and I would then know not to register the volume listeners. Having a listener to know when the output device changes would be nice, but I could poll getVolume, handle the exception, and use this as my mechanism. |
One thing that would be good would be to mention this on the readme page, could save someone else some time in wondering why it isn't working for them. Thanks |
I'm running my Flutter app on a MacOS Ventura 13.3.1 and calling all of the APIs results in errors of the following code. I'm running my app off the command line 'flutter run -d macos'. I've read the readme files and not see there any permissions to set or initialisation procedure that I must do and I'm just copying the examples.
PlatformException(1004, Failed to register volume listener, The operation couldn’t be completed. (flutter_volume_controller.Sound.SoundOutputManager.Errors error 1.), null)
PlatformException(1000, Failed to get volume, The operation couldn’t be completed. (flutter_volume_controller.Sound.SoundOutputManager.Errors error 1.), null)
I've done a flutter clean and rebuild but that didn't change anything. A Google search did not yield any results, hence my post here as I don't currently see what else to try as the API is pretty straight forward.
The text was updated successfully, but these errors were encountered: