Suggestions

close search

StringeeStream

public class StringeeStream
extends Object



Represents a media stream.



Summary


Nested classes
public interface StringeeStreamListener

Monitors when the stream available to be displayed.

public static class StringeeStreamStats

Used to get the stream's statistics such as: bytesReceived, packetsReceived, packetsLost.

public interface StringeeStreamStatsListener

Monitors the stream's statistics.

Public Constructors
StringeeStream(Context context)

Creates a new StringeeStream instance.

StringeeStream(Context context, StringeeStreamConfig streamConfig)

Creates a new StringeeStream instance with configurations.

Public methods
void enableVideo(boolean enabled)

Enable or disable video of the stream.

void getStats(StringeeStreamStatsListener listener)

Get the stream's statistics such as: bytesReceived, packetsReceived, packetsLost.

SurfaceViewRenderer getView()

Gets the view which the stream renders video to.

String getId()

Returns the stream's id.

void mute(boolean mute)

Toggle the stream's audio on or off

void renderView(boolean isMediaOverlay)

Displays the stream's video..

void setStreamListener(StringeeStreamListener streamListener)

Set a StringeeStream.StringeeStreamListener object to monitors when the stream's video available to be displayed.

void switchCamera()

Switches the device's camera. By defalt, Stringee SDK uses the front camera.


Public constructors


StringeeStream

StringeeStream(Context context)

Creates a new StringeeStream instance.

Parameters
context

The Android application context associated with the stream.



StringeeStream

StringeeStream(Context context, StringeeStreamConfig streamConfig)

Creates a new StringeeStream instance with configurations.

Parameters
context

The Android application context associated with the stream.

streamConfig

The StringeeStreamConfig instance.



Public methods


enableVideo

void enableVideo(boolean enable)

Enable or disable video of the stream.

Parameters
enable

True to enable or false to disable video.



getStats

void getStats(StringeeStreamStatsListener listener)

Get the stream's statistics such as: bytesReceived, packetsReceived, packetsLost.

Parameters
listener

The StringeeStream.StringeeStreamStatsListener instance.



getView

SurfaceViewRenderer getView()

Gets the view which the stream renders video to.



getId

String getId()

Returns the stream's id.



mute

void mute(boolean mute)

Toggle the stream's audio on or off

Parameters
mute

True to toggle audio off or false to toggle audio on.



renderView

void renderView(boolean isMediaOverlay)

Displays the stream's video.

Parameters
isMediaOverlay

Control whether the video is placed on top of another regular surface view in the window.



setStreamListener

void setStreamListener(StringeeStreamListener streamListener)

Set a StringeeStream.StringeeStreamListener object to monitors when the stream's video available to be displayed.

Parameters
streamListener

A StringeeStreamListener instance.



switchCamera

void switchCamera()

Switches the device's camera. By defalt, Stringee SDK uses the front camera.