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

Subscribers are not able to hear/see the audio/video from a video played while screen sharing #502

Closed
Kunal-KP opened this issue May 9, 2021 · 8 comments
Labels
bug Something isn't working

Comments

@Kunal-KP
Copy link

Kunal-KP commented May 9, 2021

Bug Report

Current behavior
When the publishers shares their screen which plays a video in a webview, none of the subscribers are able to see the video, nor are they able to hear the audio from the video. The video screen shows a dormant screen. Even the publishers own audio is not audible.

Steps to reproduce

  1. Start a session containing many participants.
  2. Allow the publisher to share their screen which plays a video in a webview.
  3. The video and audio works fine on the publisher's end but none of the other participants are able to see the video nor are they able to hear the audio from the video. Moreover, the publishers own audio is also not audible.
  4. The screen sharing works perfectly fine while sharing PDF's and other non multimedia content.

Example Project
As soon as screen share button is clicked, a second instance of OTPublisher component is created having videoSource='screen' in its publisher properties. But once the video starts playing, it is disabling the audio from the initial OTPublisher component and also neither the audio is heard nor the video is visible to the participants from the video that is being played on the webview

What is the current bug behavior?
When the publishers shares their screen which plays a video in a webview, none of the subscribers are able to see the video, nor are they able to hear the audio from the video. The video screen shows a dormant screen. Event the publishers own audio is cut off.

What is the expected correct behavior?
The subscribers should be able to see the video and hear the audio from the video that the publisher has shared. Also the subscribers should be able to hear the publishers own voice.

Relevant logs and/or screenshots
Initially we have a single OTPublisher component where videoSource='camera':

As soon as screen share button is clicked, a new OTPublisher component is created with videoSource='screen' in its publisher properties

@msach22
Copy link
Contributor

msach22 commented May 10, 2021

Maybe @ggoldens or @enricop89 can help :)

@abdulajet
Copy link
Contributor

hey @Kunal-KP can you share a project with the broken behavior so someone can take a look and help

@abdulajet abdulajet added the bug Something isn't working label May 17, 2021
@Kunal-KP
Copy link
Author

Hi @abdulajet, let me try to explain the scenario with a couple of snippets:

When i am clicking on share screen button i am creating a new object:
{isScreenShareEnabled
? (
<OTPublisher
properties={{
videoSource: 'screen',
publishVideo: true,
publishAudio: true
}}
eventHandlers={this.publisherEventHandler}
/>
) : null}

and navigating to a screen which has a webview(react-native-webview package) rendering PDF's, multimedia files etc.:

  <WebView
        ref={(webview) => {
          this.myWebView = webview;
        }}
        allowsInlineMediaPlayback
        style={{ flex: 1, marginTop: 20 }}
        originWhitelist={['*']}
        allowFileAccess
        source={{ uri: fileURLPath }}
        allowUniversalAccessFromFileURLs
        javaScriptEnabled
        domStorageEnabled
        onMessage={this.onWebViewMessage}
        cacheEnabled={false}
        allowingReadAccessToURL={content_path}
        mediaPlaybackRequiresUserAction={false}
        injectedJavaScript={webViewJs}

      />

Please note: The screen share works perfectly fine for PDF's and animations and the participants are able to see the content and also simultaneously hear the audio of the presenter, but in case of multimedia content having audio/video, as soon as the multimedia content is loaded on the webview and the screen is shared, the audio of the presenter is no more audible to the participants and the participants cannot see the video or hear the audio being screen shared from the multimedia content.

The functionality works fine from the presenter's end i.e. they can hear the audio and see the video from the multimedia content rendered from the webview.

The problem exists where the audio/video from the multimedia content is unable to be streamed to the participants via the opentok-react-native sdk.

Hope you can help me with this issue.

@stanciualex
Copy link

stanciualex commented Nov 18, 2021

any fix/workaround @Kunal-KP ?

@kundanthe
Copy link

Any fix you got @Kunal-KP ?

@sangampandey
Copy link

@stanciualex @kundanthe I had similar issue whenever you screen share the audio stream is never passed from opentok you need to getMicStreams and pass it to the OpenTok API.

@pietgk
Copy link
Contributor

pietgk commented Sep 18, 2023

any status update?

@beHaze
Copy link

beHaze commented Jul 10, 2024

We have released 2.27.6 (2.28.0 coming this week) please try with these versions. Reach out to Vonage support (https://api.support.vonage.com/hc/en-us) if you’re still facing issues.

@beHaze beHaze closed this as completed Sep 18, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

8 participants