Interface CameraLive

  • All Superinterfaces:
    Stream

    public interface CameraLive
    extends Stream
    Camera live stream control interface.

    Provides control over the drone camera live stream, allowing to pause, resume or stop playback.

    There is only one instance of this interface that is shared amongst all clients that have an open reference on this stream.

    This stream supports suspension. When it is started and gets interrupted because another stream starts, or because streaming gets disabled globally, then it will move to the SUSPENDED state.
    Once the interrupting stream stops, or streaming gets enabled, then it will try and be resumed in the state it was before suspension.
    Also, this implies that this stream may be started even while streaming is globally disabled. In such a case, it will move to the SUSPENDED state until either it is Stream.State.STOPPED by client request, or streaming gets enabled.

    The stream is neither stopped nor released when the reference that provides it is closed.

    • Method Detail

      • playState

        @NonNull
        CameraLive.PlayState playState()
        Informs about current playback state.
        Returns:
        current playback state
      • play

        boolean play()
        Requests playback to start.

        This method will try and start the stream if necessary.

        Returns:
        true if playback request was sent, otherwise false
      • pause

        boolean pause()
        Requests playback to pause.

        This method will try and start the stream if necessary.

        Returns:
        true if playback request was sent, otherwise false
      • stop

        void stop()
        Stops the stream.

        This method will bring the stream to the Stream.State.STOPPED state.*