ICatchIStreamPublish interface

  1. package com.icatchtek.pancam.customer.stream;
  2. public interface ICatchIStreamPublish {
  3. ...
  4. }

This interface contains methods to push stream to a specified rtmp-server, such as youtobe.

Public methods

startPublishStreaming

  1. boolean startPublishStreaming(java.lang.String rtmpUrl)
  2. throws com.icatchtek.reliant.customer.exception.IchStreamNotRunningException,
  3. com.icatchtek.reliant.customer.exception.IchStreamNotSupportException,
  4. com.icatchtek.reliant.customer.exception.IchStreamPublishException

Start publish streaming to rtmp-server
Parameters:

  • rtmpUrl - The rtmpUrl which you want to push stream to.

Returns:
Operations succeed, return true, otherwise return false.
Throws:

  • com.icatchtek.reliant.customer.exception.IchStreamNotRunningException - The session is closed or not prepared.
  • com.icatchtek.reliant.customer.exception.IchStreamNotSupportException - The stream video or audio format is not supported
  • com.icatchtek.reliant.customer.exception.IchStreamPublishException - The streaming publish state error

stopPublishStreaming

  1. boolean stopPublishStreaming()
  2. throws com.icatchtek.reliant.customer.exception.IchInvalidArgumentException,
  3. com.icatchtek.reliant.customer.exception.IchStreamNotRunningException,
  4. com.icatchtek.reliant.customer.exception.IchStreamPublishException

Stop publish streaming to rtmp-server
Returns:
Return true if no error occurred, otherwise return false.
Throws:

  • com.icatchtek.reliant.customer.exception.IchInvalidArgumentException - The streaming publish flow error.
  • com.icatchtek.reliant.customer.exception.IchStreamNotRunningException - The session is closed or not prepared.
  • com.icatchtek.reliant.customer.exception.IchStreamPublishException - The streaming publish state error

isStreamSupportPublish

  1. boolean isStreamSupportPublish()
  2. throws com.icatchtek.reliant.customer.exception.IchStreamNotRunningException,
  3. com.icatchtek.reliant.customer.exception.IchStreamNotSupportException

Get streaming state whether it can supported publish
Returns:
Return true if no error occurred, otherwise return false.
Throws:

  • com.icatchtek.reliant.customer.exception.IchStreamNotSupportException - The streaming is not support to publish.
  • com.icatchtek.reliant.customer.exception.IchStreamNotRunningException - The session is closed or not prepared.

createChannel

  1. java.lang.String createChannel(ICatchGLCredential credential,
  2. java.lang.String resolution,
  3. java.lang.String broadCastTitle,
  4. boolean vrProjection)

Create Channel on youtube Live website.
Parameters:

  • credential - credential which is defined in ICatchGLCredential
  • resolution - resolution of streaming
  • broadCastTitle - Title of broadcast
  • vrProjection - is vr streaming

Returns:
The URL of push streaming
Throws:

  • com.icatchtek.reliant.customer.exception.IchStreamNotSupportException - The streaming is not support to publish.
  • com.icatchtek.reliant.customer.exception.IchStreamNotRunningException - The session is closed or not prepared.

deleteChannel

  1. void deleteChannel()

Delete channel on youtube Live website

startLive

  1. java.lang.String startLive()

Start Live
Returns:
the URL of shared

stopLive

  1. void stopLive()

Stop Live