startProcessing

abstract suspend fun startProcessing(inputStream: MediaStream, background: VirtualBackground, onProcessedFrame: (ProcessedFrame) -> Unit? = null): MediaStream?

Start processing the input video stream with the given background.

Return

The processed video stream with virtual background applied

Parameters

inputStream

The camera video stream to process

background

The virtual background to apply

onProcessedFrame

Optional callback for each processed frame (for preview)