LocalUser Vs. LocalVideoTrack
Closed this issue · 2 comments
What kind of problem do you need help?
As I understand it, it is recommended we use the LocalVideoTrack
component instead of the LocalUser
component. If that is so, Will LocalVideoTrack
support properties such as:
- micOn
- cameraOn
- cover
If not, how else can we achieve tasks such as muting camera and mic, and setting the cover image?
<LocalVideoTrack>
is a low level component which only holds the video player (i.e. a <div>
) and take responsibility to play or stop a local video track. So it does not control the microphone nor display a cover image. We believe providing this fine-grained API could let users construct any layout as they want, including the <LocalUser>
.
This repo also provides examples about using these components, some common practices (like displaying a local user and render controls) are in another folder. As you can see the implementation is quite simple using these low level APIs.
@divanov11, as hyrious mentioned, <LocalVideoTrack>
is a low level Component.
agora-rtc-react
is the core and there is no plan to provide more complex components.
However, we are happy to consider that as uikit in agora-rtc-react-ui
, please look forward to our future updates.