capture Canvas Stream
Captures the canvas stream and handles the transport connection for whiteboard streaming.
This function manages the lifecycle of canvas stream capture for whiteboard recording:
When start is
true: Captures the whiteboard as a video stream and connects the transportWhen start is
false: Stops the canvas stream tracks and disconnects the transport
Platform Support:
Android: Uses WhiteboardVideoCapturer to render shapes to video frames
iOS: Uses Core Graphics to render shapes to video frames
Web: Uses HTML Canvas's
captureStream()API via JavaScript interop
Example:
val options = CaptureCanvasStreamOptions(
parameters = myParameters,
start = true
)
captureCanvasStream(options)Content copied to clipboard
To stop the canvas stream:
val options = CaptureCanvasStreamOptions(
parameters = myParameters,
start = false
)
captureCanvasStream(options)Content copied to clipboard