IrisRtcStreamDelegate Protocol Reference

Conforms to NSObject
Declared in IrisRtcStream.h

Overview

The IrisRtcStreamDelegate protocol defines the optional methods implemented by delegates of the IrisRtcStream class.

IrisRtcStream class when it creates a camera instance and starts the capture, calls the delegate method onLocalStream:mediaTrack: with the media tracks.

The application can then use mediatrack APIs to add a renderer to it to start the local preview.

In case the IrisRtcStream class has errors while opening the camera or during camera capture process, it will call the onStreamError:error:withAdditionalInfo: delegate method. The additional info will have additional details on the errors. While the error will be according to Iris Error Codes. The most common error codes will happen if the camera instance was not found (due to system level error) or if the camera doesnt support the the video quality setting or the hardware does not have the correct camera type.

– onLocalStream:mediaTrack: required method

This method is called when the local preview is available

- (void)onLocalStream:(IrisRtcStream *)stream mediaTrack:(IrisRtcMediaTrack *)mediaTrack

Parameters

stream

Pointer to the stream object.

mediaTrack

Media track that is associated with the camera instance.

Discussion

This method is called when the local preview is available

Declared In

IrisRtcStream.h

– onStreamError:error:withAdditionalInfo: required method

This method is called when there in an error during camera capture processs

- (void)onStreamError:(IrisRtcStream *)stream error:(NSError *)error withAdditionalInfo:(NSDictionary *)info

Parameters

stream

Pointer to the stream object.

error

Error code and basic description.

info

Additional details for debugging.

Discussion

This method is called when there in an error during camera capture processs

Declared In

IrisRtcStream.h