react-native-twilio-video-webrtc icon indicating copy to clipboard operation
react-native-twilio-video-webrtc copied to clipboard

Is it supported to Specify Video Constraints?

Open LucasBruzzone opened this issue 6 years ago • 6 comments

Hello. I'm trying to make a video call between a cellphone and a computer with twilio, but the video in the computer gets totally expanded. I wanted to know if there are ways to specify the video constraints right now in the library, as I looked for a while and didn't found anything. I know with twilio this can be archieved as specified here https://www.twilio.com/docs/video/specifying-video-constraints Thanks

LucasBruzzone avatar Aug 15 '19 15:08 LucasBruzzone

You can specify the constraints but that still doesn't give you a hard guarantee on the dimensions of the video you'll receive on the desktop.

FWIW, what I end up doing is putting in the video in a div with objectFit: cover and height and width set up in a reasonable way.

slycoder avatar Aug 16 '19 06:08 slycoder

@slycoder How do you actually specify constraints with your API? I didn't see any options do that listed in your docs.

Also, on another note, have you seen any mobile carriers throttle upstream video bandwidth? You said that use Twilio Video for work. I find that if a mobile device drops from WiFi and does a handoff to cellular, then there is a short burst of high-quality video, and then the quality on the receiving end drops of and bottoms out really low. The remote video on the device, however, doesn't suffer any changes. (I can make this into it's own issue if you want).

jcorkhill avatar Jan 14 '20 22:01 jcorkhill

And in addition to the above, @slycoder, why are the min and max FPS values hardcoded over here?

https://github.com/blackuy/react-native-twilio-video-webrtc/blob/09a2c610dba40fb4dbaab3a0921a42dd42b8d054/android/src/main/java/com/twiliorn/library/CustomTwilioVideoView.java#L185

I feel that that should be something that is part of the API.

jcorkhill avatar Jan 14 '20 22:01 jcorkhill

You're right, the constraints aren't easily exposed; if you want to submit a PR it would be very welcome!

As for the bursty behavior you've seen, I've seen it from time to time (it doesn't happen often in our use case though); do you have a suggestion for how to better set things up to prevent that?

slycoder avatar Jan 20 '20 02:01 slycoder

And in addition to the above, @slycoder, why are the min and max FPS values hardcoded over here?

https://github.com/blackuy/react-native-twilio-video-webrtc/blob/09a2c610dba40fb4dbaab3a0921a42dd42b8d054/android/src/main/java/com/twiliorn/library/CustomTwilioVideoView.java#L185

I feel that that should be something that is part of the API.

@slycoder it is possible to override that harcoded settings in elegant way (es. without forking repo)?

emacaste avatar Jun 05 '20 08:06 emacaste

Unfortunately at the moment there isn't an easy way to do this without digging into the native code. It shouldn't be hard to fix this but I haven't had time to do it.

slycoder avatar Jun 06 '20 05:06 slycoder