Starts the live streaming. If the manager starts successfully, isStreaming will return true. The encoder will start to encoding the video frame if it is needed. The video will be streamed to the RTMP server if the server is available. The audio can be streamed along with the video if the audio setting is enabled.
Return:
synchronized int
An int value of the error code. 0 means success. 254 means initialization error. -2,means livestream feature is disabled by LDM. -3 means failure to obtain sps/pps.
Enables/disables the audio streaming. When it is enabled, the audio received by the mobile device's microphone will be streamed to the RTMP server along with the video. This setting will take effect before startStream is called. Changing this setting after startStream is called requires restarting the streaming. The audio can be muted during the streaming by calling setAudioMuted.
Input Parameters:
boolean enabled
Pass true to enable the audio streaming, false to disable the audio streaming.
Enables/disables the video encoding by force for the live streaming. The basic workflow to process the video feed from the aircraft is to decode first and then encode again with a specific bit rate into H.264 stream. Therefore, video encoding is required in default. For some drones like Mavic Pro, the original video feed from Mavic Pro remote controller can be streamed to a RTMP server directly, so the video encoding is disabled for Mavic Pro, however, the bit-rate of the original video is very high, by enabling this flag, the original video will be decoded and encoded to a lower speed video stream.
Input Parameters:
boolean enable
Pass true to enable the Video Encoding, false to disable the Video Encoding.