Is it possible to set built-in speaker as main (sounds will go from its) if headphones are plugged in? How can I do it? Thanks..
Asked
Active
Viewed 78 times
-2
-
2What have you tried? And why do you think that your app should overturn the user wish to use a connected headset? – GhostCat Dec 31 '17 at 14:19
1 Answers
0
I believe it is entirely dependent on the hardware architecture of the device in use and the audio codec. It does seem to be possible to set the preferred device via the "Audio Routing" interface, specifically the setPreferredDevice()
method.
This looks to be an updated implementation of the ability to force this via the "Audio System" interface that was found in previous versions. The complete documentation for the interface can be found here.

Jordan Craig
- 128
- 7