kclyu / rpi-webrtc-streamer

This repo's objective is providing something like Web Cam server on the most popular Raspberry PI hardware. By integrating [WebRTC](https://webrtc.org/native-code/) and Raspberry PI, we can stream the Raspberry camera feed to browser or native client which talks WebRTC.
Other
617 stars 108 forks source link

Where to define constraints? #94

Closed drewcovi closed 4 years ago

drewcovi commented 4 years ago

Thanks in advance for your insights: does the client typically determine constraints and request height and width? If so, where would I be able to override this in the web client code? It seems like the raspberry pi zero w could be more performant if lower resolutions were requested. Otherwise, is it possible to override raspicam defaults?

kclyu commented 4 years ago

This is done entirely in RWS rather than in the client for changes in video width/height. RWS will change the appropriate video width/height according to the bandwidth estimation with the client.

If you want to adjust the screen resolution on the client, there seems to be a way to adjust the max bandwidth. I haven't tested it yet, but it seems possible because limiting the max bandwidth on the client will pass it to RWS.

To adjust in RWS, it seems that you can delete the unwanted video resolution from the video_resolution_list in media_config.

drewcovi commented 4 years ago

Thanks!