Can we change the video quality in between the call

2,149 views
Skip to first unread message

Rishi Khandelwal

unread,
Nov 19, 2013, 8:15:08 AM11/19/13
to discuss...@googlegroups.com
Hello

My scenario is that if bandwidth is good then show 720p or more quality video and if bandwidth is low the show 240 p quality video.

When connection will be created then it will check bandwidth and will show video according to that. 

But, if during the call , say bandwidth increases then is it possible that we can show high quality video ?

Vikas

unread,
Nov 19, 2013, 2:41:33 PM11/19/13
to discuss...@googlegroups.com
Hi,

One option could be that you call getUserMedia to get low resolution stream when you find the bandwidth is low then remove the old stream, add new stream & renegotiate.Also there are still some discussions about various ways resolution changes can be handled, see issue 2483.

/Vikas

Rishi Khandelwal

unread,
Nov 29, 2013, 1:33:11 AM11/29/13
to discuss...@googlegroups.com
HI Vikas,

As you said that first remove old stream and then create new stream, it is not going to be a good solution. Because if we will remove old stream then first user will get blank and then he will get new stream. But it will be valid only for local stream. But i am talking about remote streaming which is coming to us.

My problem :
Actually when bandwidth is low at my end, then i got bad streaming of another user like voice is breaking, video is not continuous...So i want that if my bandwidth is low then i will get remote stream according to bandwidth. Is it possible ?

Alexandre GOUAILLARD

unread,
Nov 29, 2013, 3:42:10 PM11/29/13
to discuss...@googlegroups.com
even if you lower the resolution, webRTC will still try to use up to 2M. You need to explicitly handle bandwidth.


--
 
---
You received this message because you are subscribed to the Google Groups "discuss-webrtc" group.
To unsubscribe from this group and stop receiving emails from it, send an email to discuss-webrt...@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.

Rishi Khandelwal

unread,
Dec 3, 2013, 5:27:57 AM12/3/13
to discuss...@googlegroups.com
I didn't get clearly.


My point is that :

Say, I am running my video in 720p.

When i get good bandwidth then everything works fine, but when i get bad bandwidth then video and audio doesn't work fine.

So i want that either my bandwidth is good or bad, my video/audio must work fine.

Ho can i achieve this ?

I have a solution for this, i don't know whether it is possible or not .

Solution : Initially at the time of connection, it will check bandwidth, if it is bad , then it will show less resolution video (Higher resolution video takes more bandwidth)m, and in every 60 seconds, it will check bandwidth. If it finds bandwidth good, then it will change the video resolution to higher one.

Is it possible in WebRTC ?
Message has been deleted

Alexandre GOUAILLARD

unread,
Dec 3, 2013, 5:42:49 AM12/3/13
to discuss...@googlegroups.com
by default, you cannot change the spatial resolution of an ongoing call without renegotiating.
nothing prevents you from monitoring the bandwidth (through the stats API) and renegotiating when you want to. renegociation comes at a cost as you have to remove the stream from the peer connection, call again GUM with different constraints, and go through the SDP O/A and ICE checking again, during which no stream is sent.

now, the VP8 codec is adaptive which means, it will adapt the quality of the video (*without changing its resolution*) depending on network conditions. It actually starts very low (around50k) and slowly ramps up to 2M or the maximum bandwidth available whichever is smaller.

"work fine" is an ill-defined term here. By default you won't lose connection (ICE might disconnect and reconnect under super low bandwidth, video freezes, but it comes back). The quality of the video call will be lowered, but you might not actually perceive it. I'm not convinced that changing the spatial resolution is something you want to do practically.

try it yourself using apprtc.appspot.com over a low bandwidth connection, and open chrome://webrtc-internals on a separate window to check the bandwidth usage. in that page you should shave a BWE-video graph, that illustrates what I just said. I attached two experiments I did several months ago to illustrate the ramp up, and the bandwidth adaptation.


On Tue, Dec 3, 2013 at 6:28 PM, Rishi Khandelwal <ri...@knoldus.com> wrote:


On Tuesday, December 3, 2013 3:57:57 PM UTC+5:30, Rishi Khandelwal wrote:
I didn't get clearly.


My point is that :

Say, I am running my video in 720p.

When i get good bandwidth then everything works fine, but when i get bad bandwidth then video and audio doesn't work fine.

So i want that either my bandwidth is good or bad, my video/audio must work fine.

How can i achieve this ?

I have a solution for this, i don't know whether it is possible or not .

Solution : Initially at the time of connection, it will check bandwidth, if it is bad , then it will show less resolution video (Higher resolution video takes more bandwidth)m, and in every 60 seconds, it will check bandwidth. If it finds bandwidth good, then it will change the video resolution to higher one.

Is it possible in WebRTC ?

--
Screen Shot 2013-04-26 at 1.30.41 PM.png
Screen Shot 2013-04-26 at 2.00.29 PM.png
Reply all
Reply to author
Forward
0 new messages