voximplant / react-native-demo

React Native Voximplant Demo
173 stars 146 forks source link

Conflict with 'react-native-webrtc' #98

Open lazhrach20 opened 2 years ago

lazhrach20 commented 2 years ago

Hello.

Trying use with 'react-native-webrtc' but unfortunately a conflict occurs while building the application. Since VoxImplant includes the VebRTC api, in theory, is it possible to access the RTCPeerConnection api using the Voximplant SDK for React Native. Please give example how this can be implemented.

Thanks in advance!

YuliaGrigorieva commented 2 years ago

Hello @lazhrach20,

Unfortunately, it is not possible. Voximplant React Native SDK exposes native API of Voximplant Android and iOS SDK, but not the WebRTC API and we do not plan to expose them in future releases.

Could you please provide some more details about your case? What would you like to do with RTCPeerConnection API that Voximplant React Native SDK does not allow to do with the Voximplant platform?

Best regards, Yulia Grigorieva

lazhrach20 commented 2 years ago

Hello! Thank you for your response! The problem I had encountered is the following. I have a pear-to-pear video chat React Native app. I want to split the initial video stream and send one of them (with low quality) to the WebRTC server running on python. The low-quality stream will be processed on the server by ML tools and sent back WebRTC stream to the VoxImplant. How can I implement a VoxImplant-to-Server connection using only VoxImplant sdk, please? Best regards, Hrachya.

YuliaGrigorieva commented 2 years ago

Hello @lazhrach20,

Thank you for providing the details.

Unfortunately, it is not possible to implement with Voximplant React Native SDK and I doubt that it is possible with react-native-webrtc.

If I understand correctly your case, you need to make a custom video source from a remote video track (received from WebRTC python server) and set this custom video source as the video source for p2p chat.

To do that it is required to have a strong integration in native code for managing media stream tracks and video sources through native WebRTC API and sharing a raw media stream between two PeerConnections.

I may be wrong, but even if all these technical issues were resolved, there would have been an unpredictable and quit big delay in p2p chat.

Best regards, Yulia Grigorieva