Open nmonasterio opened 2 years ago
@nmonasterio Thanks for submitting this request. There are multiple users requesting for the guide on how to enable Voice Focus by default. I need to confirm with the team whether SDK is able to support it or not. For now I know that before joining the meeting, SDK supports enabling the Voice Focus in the device setup process. But users have to enable it manually. We implemented this process in our JS SDK meeting demo. Could you please check this demo first to see if it helps? We will post the update later.
Thanks, @xuesichao! Checking into the JS demo right now. I've tested out the React App demo and, while you can specify whether to enable webAudio
, it still does not support enabling it by default. I'll pull down this and run/deploy just for good measure and let you know.
@xuesichao Yes, it seems the JS demo does support enabling it by default, which is great. Let me see if I can follow the code path and see how it could also be applied to the React component library. I'm glad I'm not the only one wondering about how to implement such a feature.
@nmonasterio Good to hear that! You must already know that recently we added VoiceFocusProvider
, useVoiceFocus
hook and AudioInputVFControl
to React Component Library to help you quickly enable the Amazon Voice Focus.
In Amazon Chime React Component Library, for now we only support enabling Amazon Voice Focus via MeetingControls
- AudioInputVFControl
after user join a meeting. The logic of device selection in device setup process (MicSelection
component) is similar to the audio device selection in MeetingControls
. They both use useAudioInputs
hook to get the device list and select a device.
For AudioInputVFControl
, I checked the implementation, the key logic here is:
AudioInputVFControl
uses addVoiceFocus
function exposed by useVoiceFocus
hook to transform the selected audio device to Amazon Voice Focus device.Check the code of main logic here and here.
I would highly recommend you to check the implementation of AudioInputVFcontrol
. I think you have to implement your own MicSelection
component, which follows the similar logic of AudioInputVFControl
. I haven't tried this myself, but most likely it should work.
I will bring this up to the team next Monday, to see if we can do something to help the users quickly enable Amazon Voice Focus by default, as well as the Android device echo issue, since you can not reproduce it in the WebRTC sample.
Thank you, @xuesichao. Yes, a normalized API for auto-enabling would be great, especially given the fact that, without it, the state of the VF component might get stale (i.e., the checkbox/label could get out of sync with the actual state of the VF setup) but I'll take a peek at your code paths as well and see where that might lead.
And thank you as well for looking at the Android echo issue. Much appreciated!
@nmonasterio I'm trying to find some action items for this issue. Since you are using the React Component Library, would you like to submit a feature request there about the feature you need? This would help us tracking the user need.
For JS SDK repo, do you think a FAQ or how-to doc on how to enable Voice Focus for all devices upon joining the meeting and/or switching devices would help you?
@xuesichao That sounds like a plan. I'll open up a feature request there.
And yes, a how-to on how to do from the JS SDK would suffice for the time being.
Thanks!
Am I correct in understanding that the only way to enable VoiceFocus by default is to use the JS SDK? Is manual switching the only way to do this in ReactComponent?
What are you trying to do?
I'm trying to enable Voice Focus on by default, as it appears to be the only way to prevent echo on some Android devices.
For example: I'm trying to start a meeting session with audio.
How can the documentation be improved to help your use case?
I'd like to see how one could enable VoiceFocus for all devices, upon joining the meeting and/or switching devices.
I am able to create a transformed device with VoiceFocus using
VoiceFocusDeviceTransformer.create()
and subsequently passing the device ID of the device I want to apply it to, but it does not seem to apply it when provided.My approach so far:
For example: Include a section on how to configure the meeting session.
What documentation have you looked at so far?
These docs, the the developer guide as well as the React SDK.
*For example: README.md, Amazon Chime SDK Developer Guide, etc.