Skip to content

RtkVideoView

Renders a participant's video stream. Supports self-preview, remote participant video, and screen share rendering.

Initializer parameters

ParameterTypeRequiredDefaultDescription
participantRtkMeetingParticipant-The participant whose video to render
showSelfPreviewBoolfalseWhether to show the local camera preview
showScreenShareBoolfalseWhether to show the screen share stream instead of camera

Methods

MethodReturn TypeDescription
reattachRenderer()VoidReattaches the video renderer to the participant stream
prepareForReuse()VoidPrepares the view for reuse in a collection or table view
clean()VoidReleases the video renderer and cleans up resources

Usage Examples

Basic Usage

Swift
import RealtimeKitUI
let videoView = RtkVideoView(participant: participant)
view.addSubview(videoView)

Self-preview

Swift
import RealtimeKitUI
let previewView = RtkVideoView(
participant: localParticipant,
showSelfPreview: true
)
view.addSubview(previewView)

Screen share

Swift
import RealtimeKitUI
let screenShareView = RtkVideoView(
participant: participant,
showScreenShare: true
)
view.addSubview(screenShareView)