rtcService.remoteVideoTrack in later SDK versions
Hi,
I was previously using the remoteVideoStream method of RTCService to get/render the remote video stream of a video call. Since upgrading the SDK, I have replaced this with the remoteVideoTrack method but now the remote video track is just blank. The notification for the remote video track being added is called but there is no stream. This happens for both version 1.85.0 and 1.86.0 of the SDK.
Any ideas?
-
This is still happening in the latest LTS version of the SDK (2.4.0). I'm adding the remote video track to the view (RTCMTLVideoView) in the didAddRemoteVideoTrack event but the stream does not render. If I fall back to the previous method as described above, the remote video stream renders correctly
-
This is the code that works:
if let remoteVideoStreams = ServicesManager.sharedInstance()?.rtcService.remoteVideoStream(for: self.currentCall!) {
if remoteVideoStreams.videoTracks.count > 0 {
remoteVideoTrack = remoteVideoStreams.videoTracks[0]
}
}This is the code that presents a blank view/stream
remoteVideoTrack = ServicesManager.sharedInstance()?.rtcService.remoteVideoTrack(for: self.currentCall!)
-
Thanks Rick, yes it's expected to get the same results for both codes.
To compare the tracks values, could you please try to log the remoteVideoTrack in both cases, and also to log remoteVideoStreams.videoTracks to check the list of video tracks in the remoteVideoStreams.
Also it will help if you can share the full logs when run the tests.
-
The log is 100's of lines and will be too large to paste here. Is there a way to send it to you directly? via the Rainbow app maybe? Or is there a specific section you're looking for?
NSLog here:
2022-06-02 17:03:31.171534+0930 FitMed[42064:2955061] remoteVideoTrack: RTC_OBJC_TYPE(RTCMediaStreamTrack):
video
b7fe46a8-2952-4d99-aef9-a728d20ab629
enabled
Live
2022-06-02 17:03:31.171984+0930 FitMed[42064:2955061] remoteVideoTrack2: RTC_OBJC_TYPE(RTCMediaStreamTrack):
video
b7fe46a8-2952-4d99-aef9-a728d20ab629
enabled
Live
-
It's okay, no need to share full logs for now, where from the tracks logs we see that both tracks look identical.
When render the video track, can you try to remove the renderer first before adding the renderer to see if this could help to avoid the problem when use remoteVideoTrack.
Vous devez vous connecter pour laisser un commentaire.
Commentaires
11 commentaires