com.supermap.ai.mediaservice

Class MediaService

  • java.lang.Object
    • com.supermap.ai.mediaservice.MediaService


  • public class MediaService
    extends java.lang.Object
    • Constructor Detail

      • MediaService

        public MediaService(android.content.Context context)
        Parameters:
        context -
    • Method Detail

      • setPushService

        public void setPushService(java.lang.String ip,
                                   java.lang.String port,
                                   java.lang.String id,
                                   InitCallback callback)
        Sets the push-flow service address
        Parameters:
        ip - ip address of rtsp server
        port - the port of rtsp server.
        id - id name of plug flow
        callback -
      • startPushCameraView

        public void startPushCameraView()
        Starts to post the camera view
      • pausePushRenderView

        public void pausePushRenderView()
        Stops posting the camera view
      • startPushCustom

        public void startPushCustom(android.graphics.Bitmap bitmap)
        Begins to post custom content video flow
        Parameters:
        bitmap - plug flow image
      • muteLocalAudioStream

        public void muteLocalAudioStream(boolean muted)
        Whether to mute
        Parameters:
        muted -
      • stopPushCustom

        public void stopPushCustom()
        Stops to push flow
      • setPlayerService

        public void setPlayerService(java.lang.String url)
        Sets the pull-flow address
        Parameters:
        url -
      • startPlay

        public void startPlay(java.lang.String Key,
                              android.view.TextureView textureView)
        Starts to pull flow
        Parameters:
        Key -
        textureView -
      • stopPlay

        public void stopPlay()
        Stops pulling flow
      • createLocalRenderView

        public CameraView createLocalRenderView()
        Creates local videos
        Returns:
        camera