ringcentral-embeddable icon indicating copy to clipboard operation
ringcentral-embeddable copied to clipboard

Change InputDevice during call

Open curtishollawayTSI opened this issue 5 years ago • 9 comments

We have a need to allow our users to transition a call from their headset to a usb speaker/microphone for speaker calls. The user can change the output device during the call, but not the input device. We programmatically change these and it has the same effect (the input device does not change until the call hangs up).

Is there a way to transition the input device on an active call from one to the other?

curtishollawayTSI avatar Mar 07 '20 00:03 curtishollawayTSI

Hi @curtishollawayTSI , It is not supported now. We bind the WebRTC stream to input device when call is created, and can't change during call.

embbnux avatar Mar 10 '20 13:03 embbnux

wait for https://github.com/ringcentral/ringcentral-web-phone/issues/275

embbnux avatar Mar 17 '20 15:03 embbnux

Thank you

curtishollawayTSI avatar Mar 17 '20 15:03 curtishollawayTSI

@curtishollawayTSI Can you please help me out to get the list of media devices(input devices like headset or wireless) and set for the voice call?

JSGund avatar Jul 17 '20 05:07 JSGund

@JSGund You can get media devices by calling navigator.mediaDevices.enumerateDevices(), or phone.audioSettings.availableInputDevices if you can access this app's window scope.

For set device, you can call phone.audioSettings.setData({ inputDeviceId: your_device_id }).

embbnux avatar Jul 17 '20 09:07 embbnux

@embbnux here 'phone.audioSettings.availableInputDevices' - phone means WebPhone instance right?

JSGund avatar Jul 17 '20 09:07 JSGund

@embbnux here 'phone.audioSettings.availableInputDevices' - phone means WebPhone instance right?

Not, phone is global variable in app.html. It is used for state management and business logics. For web phone instance, you can get it by phone.webphone._webphone

embbnux avatar Jul 17 '20 10:07 embbnux

In _webphone instance there are not any audioSettings method available to set this setData({ inputDeviceId: your_device_id }). Is it possible set the setData({ inputDeviceId: your_device_id }) using _webPhone instance? Let me know how to resolve this? Thanks

JSGund avatar Jul 17 '20 10:07 JSGund

In _webphone instance there are not any audioSettings method available to set this setData({ inputDeviceId: your_device_id }). Is it possible set the setData({ inputDeviceId: your_device_id }) using _webPhone instance? Let me know how to resolve this? Thanks

audioSettings isn't in _webphone instance, it is in phone global variable

embbnux avatar Jul 19 '20 06:07 embbnux