react native webrtc replace video stream with new stream - react-native

I am implement screen captured inside my webrtc application, I successfull get mediaStream + get frame from Boardcast Extension, but I dont know why I can not replace the videotrack from localVideoTrack to screen captured video track, here is my code:

Related

Streamlit-webrtc with custom video source

I'm working on a traffic detection project, where I get video stream from Youtube livestream using CamGear and then process each frame with OpenCV. I want to display final video with detections in Streamlit app. I tried passing processed frames to st.frame, but for some reason only first few frames are shown and then the video freezes. Now I am looking at using webrtc component, but I can’t figure out, how to change video source from webcam. Thanks.

Broadcasting-to multiple peer

How can we have a stream in which video and screen share in simultaneously in one single stream using webRTC so it can be send to all the peers in one stream
You need to use canvas html element and blend streams received via calls to getUserMedia (webcam) and getDisplayMedia (screen) into that canvas element.
Then take resulting blended picture from that canvas element and stream it with RTCPeerConnection.
Live example here:
https://unrealstreaming.net:8443/UnrealWebRTCPublishingDemo/publish.aspx

React native h.264 encoded video display

I am using react native and connected to PI camera. It's sending me h.264 encoded string in notification which is direct binary data. and I am trying to display this to video format. So, I am trying to find out how to display this stream as a video. and that string will update in every notification. and I found broadway (https://github.com/mbebenita/Broadway) player. which is for web view only and working perfect with my hardware. So, is there anything like this? which I can use to display h.264 encoded binary data to video using react native.

Agora WebRTC Change video call view

I am working on a react-native project which uses Agora.io for video calling.
In a video call it shows my camera feed as fullscreen and the reciever's feed as thumbnail which is the opposite of the correct way.
I want to know, Is this the way agora works or is it possible to fix this..?
Because even in their website they have put the images in that way.
image on the home page
I appreciate any help regarding to fix this.
So it seems like you are presenting the local video stream to the larger view. You would need to switch this. Render the remote video stream on the larger view and the local video stream on the thumbnail view.

Webcam light stay on when during video call but my video is turn off in tokbox

I am using Tokbox API for making video call application. But I have one problem show. During video call i show my laptop's webcam light stay ON but in call my video is turnoff. It seems like Tokbox API accessing my webcam behind the scene. How can I stop my laptop's webcam light when I turn off my video from call ?
Are you disabling video with OT.initPublisher({ publishVideo: false }) or publisher.publishVideo(false)? If so, then this is expected because we need to capture the camera in case you enable video later on in the call.
If you want to always have video disabled to have an audio only call, then please use OT.initPublisher({ videoSource: null }), this will not capture the camera at all.
See documentation for videoSource at https://tokbox.com/developer/sdks/js/reference/OT.html#initPublisher
If you set this property to null or false, the browser does not
request access to the camera, and no video is published. In a
voice-only call, set this property to null or false for each
Publisher.