Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

Thus, for the stream 1920x1080 with 2 Mbps bitrate seems optimal to play no more than 6 streams on the same page for any client can play them.

Let's test a webinar case: one desktop stream 1920x1080 with 2 Mbps bitrate and a number of webcam streams 640x360 with 500 kbps bitrate. Under the same channel conditions:

  • Intel Core i5 8 gen and newer based PC, from 8 Gb RAM: up to 25 audio+video streams, or up to 6 audio+video and 25 audio only streams
  • A flagship Android/iOS device of year 2018 and newer (Samsung S series, Apple iPhone Pro): up to 20 audio+video streams, or up to 6 audio+video and 25 audio only streams
  • A middle ol lower class device, or obsoleted Android/iOS device of year 2017 and newer: up to 10 audio+video streams, or up to 6 audio+video and 15 audio only streams

Thus, for webinar case with one desktop stream and a number of webcam streams seems optimal to play no more than 10 streams on the same page for any client can play them.

WebRTC stream playback in custom player

...

The delay is not applied to audio tracks in the stream and to audio only streams.

Known issues

1. Possible bug in the Safari browser on iOS leads to freezes while playing via WebRTC

Symptoms: video playback stops, while the audio track may continue playing. Recovery needs reloading the page or restarting the browser.

Solution:

а) enable the transcoder on the server by setting the following parameter in flashphoner.properties

Code Block
languagebash
themeRDark
disable_streaming_proxy=true

b) when playing the stream from iOS Safari explicitly specify width and height, for example:

...

languagejs
themeRDark

...

Redundancy support while playing audio

Since build 5.2.1969 a redundancy is supported while playing audio data (RED, RFC2198). This allows to reduce audio packet loss when using opus codec. The feature is configured as like as redundancy support for publishing audio.

Use the following parameter to enable redundancy for audio playback

Code Block
themeRDark
red_max_encodings_number=2

The parameter sets an additional data proportion. WebRTC library in browser usually uses a double redundancy while publishing, therefore it is recommended to set the same value for playback.

Known issues

1. Possible bug in the Safari browser on iOS leads to freezes while playing via WebRTC

Symptoms: video playback stops, while the audio track may continue playing. Recovery needs reloading the page or restarting the browser.

Solution:

а) enable the transcoder on the server by setting the following parameter in flashphoner.properties

Code Block
languagebash
themeRDark
disable_streaming_proxy=true

b) when playing the stream from iOS Safari explicitly specify width and height, for example:

Code Block
languagejs
themeRDark
session.createStream({constraints:{audio:true,video:{width:320,height:240}}}).play();

...

b) use mixer to play two or more streams on the same page

12. In Safari 16 video can be switched to a full screen mode only if a standard video controls are enabled for HTML5 video element

Symptoms: video is not displaying when switched to full screen mode, but audio still playing, after a couple of subsequents switches the page may hang

Solution: update Web SDK to build 2.0.224 and enable standard controls in player with useControls stream option:

Code Block
languagejs
themeRDark
function playStream(session) {
    var streamName = $('#streamName').val();
    var options = {
        name: streamName,
        display: remoteVideo,
        useControls: true
    };
    ...
    stream = session.createStream(options).on(STREAM_STATUS.PENDING, function (stream) {
        ...
    });
    stream.play();
}