Skip to content
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

How can I allow one-way video communications? #269

Open
jenniestrongbow opened this issue Apr 4, 2021 · 2 comments
Open

How can I allow one-way video communications? #269

jenniestrongbow opened this issue Apr 4, 2021 · 2 comments

Comments

@jenniestrongbow
Copy link

Hi,

In a two-person communication, how can I allow only one participant to receive the video from the other user?

I can implement this with the audio without a problem. But with video, I do not receive any event when the remote user stops sending video for example (onRemoteVideoStateChanged not fired).

I tried setting up the client role to broadcaster on both sides but the one-way video still does not work:

mRtcEngine.setClientRole(Constants.CLIENT_ROLE_BROADCASTER);

Thanks

@yoreland
Copy link
Contributor

yoreland commented Apr 5, 2021

Can you try this:

    ChannelMediaOptions option = new ChannelMediaOptions();
    option.autoSubscribeAudio = true;
    option.autoSubscribeVideo = false;
    int res = engine.joinChannel(accessToken, channelId, "Extra Optional Data", 0,option);

@jenniestrongbow
Copy link
Author

@yoreland, thanks for your help. But I don't see how this can help me. How do I then display the video of the remote user without sending mine? Could you please give me a bit more code? Thanks

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants