CameraVideoSource

class CameraVideoSource : VideoSource

The CameraVideoSource class manages and provides video content sourced from a device's camera.

Properties

Link copied to clipboard

Returns the list of the supported video capture formats.

Link copied to clipboard
val id: Int

Returns the unique identifier associated with the source.

Link copied to clipboard
open override var isCapturing: Boolean

Indicates whether the camera video source is currently capturing video content.

Link copied to clipboard

Returns the name assigned to the source.

Link copied to clipboard

The parameters associated with the camera video source.

Link copied to clipboard
val type: Type

Returns the type of the source.

Functions

Link copied to clipboard

Dynamically changes the video capture format once the capture is started

fun changeCaptureFormat(width: Int, height: Int, fps: Int)

Dynamically changes the video capture format once the capture is started.

Link copied to clipboard
open override fun release()

Releases resources associated with the camera video source.

Link copied to clipboard
fun setCapability(videoCapabilities: VideoCapabilities)
fun setCapability(position: Int)

Sets the video capture format.

Link copied to clipboard
fun setEventsHandler(newEventsHandler: EventsHandler?)

Sets an event handler for the camera video source to receive notifications about events

Link copied to clipboard
open override fun startCapture(): VideoTrack

Starts a video capture from this source.

Link copied to clipboard
open override fun stopCapture()

Stops the capture of video frames from the camera.

Link copied to clipboard

Switches to the next available camera source if multiple cameras are present.

Link copied to clipboard
open override fun toString(): String

Returns the name of the source in the form of a string.