Skip to content

非公式 / UnofficialCloudflare, Inc. 非提携。アカウント情報は入力しないでください。Not affiliated with Cloudflare, Inc. Do not enter Cloudflare credentials here.Official docsこのサイトについてプライバシー

RtkVideoView

最終更新 Markdown で表示Agent セットアップ

参加者のビデオストリームを描画します。 セルフプレビュー、リモート参加者の映像、画面共有の描画に対応しています。

イニシャライザーのパラメーター

パラメーター 型 必須 デフォルト 説明
participant RtkMeetingParticipant ✅ - 映像を描画する対象の参加者
showSelfPreview Bool ❌ false ローカルカメラのプレビューを表示するかどうか
showScreenShare Bool ❌ false カメラの代わりに画面共有ストリームを表示するかどうか

メソッド

メソッド 戻り値 説明
reattachRenderer() Void ビデオレンダラーを参加者のストリームに再度接続します
prepareForReuse() Void collection view または table view での再利用に備えてビューを準備します
clean() Void ビデオレンダラーを解放し、リソースを破棄します

使用例

基本的な使い方

import RealtimeKitUI

let videoView = RtkVideoView(participant: participant)
view.addSubview(videoView)

セルフプレビュー

import RealtimeKitUI

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

画面共有

import RealtimeKitUI

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

役に立ちましたか?