Keeping your resolution constant when in a screen sharing app.
- Video API
- Screen Sharing
In a typical video chat interaction, WebRTC will try to optimize video frame resolution based on factors like network kbps, CPU processing power, etc. For example, if the network is congested, WebRTC optimization lowers the resolution of the video frame sent or published.
In a screen sharing application (where a bitmap of the screen is sent via the network, and a camera is not used), this downgrading of resolution can make the subscribed image (for example, the fonts in your shared notes) appear coarse. To prevent this, you can set a flag on your publisher instructing WebRTC not to downgrade the resolution and optimize the sharing experience by other ways, say reducing frame rate. It is done as follows:
In a typical video chat session using a camera, it's recommended that you not use the above setting and let WebRTC handle the optimization on its own.
In some "point and shoot" applications (for example, pointing your mobile phone camera towards a faulty wiring and publishing that to a technician on the other side) the resolution needs to be kept constant, as the captured video information or display are critical in nature (say the specification number on a faulty wire, in the example mentioned above). In such a case, you can still set the above flag and keep the resolution constant, even though you are using the camera and not sending screen sharing bitmaps.