iOS 1对1视频 无远端画面

可以成功加入channel,但是didOccurWarning报AgoraWarningCodeInvalidView和AgoraWarningCodeInitVideo错误,有声音但没有远端画面,用demo测试正常,怎么破?

确认下有没有设置渲染视频view

func rtcEngine(_ engine: AgoraRtcEngineKit, didJoinChannel channel: String, withUid uid: UInt, elapsed: Int) {
let videoCanvas = AgoraRtcVideoCanvas()
videoCanvas.uid = uid
videoCanvas.renderMode = .hidden
videoCanvas.view = remoteVideoView
engine.setupRemoteVideo(videoCanvas)
}

remoteVideoView已创建好并添加到controller的视图上

有参考我们的demo嘛:Basic-Video-Call/One-to-One-Video/Agora-iOS-Tutorial-Swift-1to1 at master · AgoraIO/Basic-Video-Call · GitHub