AgoraRtmpStreamingState Constants Reference

Declared in AgoraEnumerates.h

AgoraRtmpStreamingState

The RTMP streaming state.

Definition

typedef NS_ENUM(NSUInteger, AgoraRtmpStreamingState ) {
   AgoraRtmpStreamingStateIdle = 0,
   AgoraRtmpStreamingStateConnecting = 1,
   AgoraRtmpStreamingStateRunning = 2,
   AgoraRtmpStreamingStateRecovering = 3,
   AgoraRtmpStreamingStateFailure = 4,
};

Constants

AgoraRtmpStreamingStateIdle

The RTMP streaming has not started or has ended. This state is also triggered after you remove an RTMP address from the CDN by calling removePublishStreamUrl.

Declared In AgoraEnumerates.h.

AgoraRtmpStreamingStateConnecting

The SDK is connecting to Agora’s streaming server and the RTMP server. This state is triggered after you call the addPublishStreamUrl method.

Declared In AgoraEnumerates.h.

AgoraRtmpStreamingStateRunning

The RTMP streaming is being published. The SDK successfully publishes the RTMP streaming and returns this state.

Declared In AgoraEnumerates.h.

AgoraRtmpStreamingStateRecovering

The RTMP streaming is recovering. When exceptions occur to the CDN, or the streaming is interrupted, the SDK attempts to resume RTMP streaming and returns this state.

  • If the SDK successfully resumes the streaming, AgoraRtmpStreamingStateRunning(2) returns.
  • If the streaming does not resume within 60 seconds or server errors occur, AgoraRtmpStreamingStateFailure(4) returns. You can also reconnect to the server by calling the removePublishStreamUrl and addPublishStreamUrl methods.

    Declared In AgoraEnumerates.h.

  • AgoraRtmpStreamingStateFailure

    The RTMP streaming fails. See the errorCode parameter for the detailed error information. You can also call the addPublishStreamUrl method to publish the RTMP streaming again.

    Declared In AgoraEnumerates.h.

    Declared In

    AgoraEnumerates.h

    X
    Is this page helpful?