The EnxStream is a derived Class from EnxRtc. It handles all Media Stream related functions to initiate, configure and to transport streams to the Media Servers. It is also used for receiving stream end-points to be played.

References: AttributesMethodsObservers

Stream Meta Data Properties

  • id – Unique Stream ID
  • local – Boolean. True for Local Stream; False for Remote Stream
  • room – JSON Object. Room Into to which the Stream is associated
  • showing – Boolean. Whether the stream is being played
  • audio – Boolean. True if the stream has Audio Track
  • video – Boolean. True if the stream has Video Track
  • screen – Boolean. True if the stream has Screen Share
  • videoSize – Size of Video Frame, defined as [minWidth, minHeight, maxWidth, maxHeight]
  • videoFrameRate – Frame Rate of Video Stream, defined as [min, max]
  • desktopStreamId – Chrome Media Source ID to be used for Screen Share
  • extensionId – Extension ID to be used for Screen Share
  • audioMuted – Boolean. True if Audio is muted
  • videoMuted – Boolean. True if Video is muted
  • attributes – videoFrameRate

Methods

Given below a categorized listing of methods:

Stream Basics

  • initStream() – To initialize a Stream

Stream Conrols

  • muteSelfAudio() – To mute/unmute audio of own published stream
  • muteSelfVideo() – To mute/unmute video of own published stream
  • switchCamera() – To switch from rear to front Camera and vice-versa to change Stream Source

Moderator Controls

Callbacks

Given below is a list of Callbacks categorized by their functions.

Streaming

  • remoteStreamAudioMute – Everyone is notified when when user’s audio is muted
  • remoteStreamAudioUnMute – Everyone is notified when when user’s audio is unmuted
  • remoteStreamVideoMute – Everyone is notified when when user’s video is muted
  • remoteStreamVideoUnMute – Everyone is notified when when user’s video is unmuted
  • audioEvent – When any action is performed on Audio track of a Stream
  • videoEvent – When any action is performed on Video track of a Stream

Hard Mute Audio

  • hardMutedAudio – Moderator is acknowledged when User’s audio stream is hard-muted
  • hardUnmutedAudio – Moderator is acknowledged when User’s audio stream is hard-unmuted
  • receivedHardMutedAudio – Participant is notified that Moderator has hard-muted his audio stream
  • receivedHardUnmutedAudio – Participant is notified that Moderator has hard-unmuted his audio stream

Hard Mute Video

  • hardVideoMute – Moderator is acknowledged when User’s video stream is hard-muted
  • hardVideoUnmute – Moderator is acknowledged when User’s video stream is hard-unmuted
  • receivedhardMuteVideo – Participant is notified that Moderator has hard-muted his video stream
  • receivedhardUnmuteVideo – Participant is notified that Moderator has hard-unmuted his video stream

Explore React Native SDK