stopScreenCaptureBySourceType
Stops screen capture.
Future<void> stopScreenCaptureBySourceType(VideoSourceType sourceType);
Details
After calling startScreenCaptureBySourceTypeto start capturing video from one or more screens, you can call this method and set the sourceType parameter to stop capturing from the specified screens.
Attention:
- This method applies to the macOS and Windows only.
- If you call startScreenCapture, startScreenCaptureByWindowId, or startScreenCaptureByDisplayId to start screen capure, Agora recommends that you call stopScreenCapture instead to stop the capture.
Parameters
- sourceType
- The type of the video source. See VideoSourceType.
Exceptions
When the method call succeeds, there is no return value; when fails, the AgoraRtcException exception is thrown; and you need to catch the exception and handle it accordingly.
- < 0: Failure.