Question / Help (SOLVED) Constant Stream Freezing to Twitch

bananaa101

New Member
Alright listen up if you are having this problem continue to read this as I did hours worth of testing and have finally figured out the problem.

Even if your internet's upload speed is more than sufficient for streaming (and don't fucking listen to testmy.net shit because its incorrect for every person I've asked to try it) you can NOT go over 4000 kbps when streaming to twitch if you are not a premium account member. They limit your bandwidth to this roughly .5MB/s cap so that even if you go up to 4500kbps, people will start to see freezing. This cap as far as I can tell is also the same with Hashd.tv and probably for any other widely used streaming site.

Next thing to note is your ping to the load server you are streaming to. This is extremely important, as it dictated whether or not my stream froze when using 4000kbps.

Download JTVPing http://www.teamliquid.net/staff/R1CH/JTVPing.zip (credit to R1CH who I believe is the same person that replied to me on this forum)

This tool is essentially the same as Xsplit's latency checking tool which can be accessed when choosing your location when editing your channel. Unsure if it works for other streaming sites or only Twitch.

It should look like this when you open it.

ZGOHA6k.png


The most important thing to note is your ping to the server. Like all things, the lower your ping, the better. This will decide your ideal bitrate.

Time of day can be a factor determining whether or not your stream will be smooth, as well as MLG events. Regardless, choose the server with the lowest ping. Jitter is also important, as it is how much your ping fluctuates to the server, but not nearly as much as your average ping to the servers

When I tested streaming at 3500kbps to New York, my stream was freezing out the ass non stop. Only when I dropped it to 3000 did it become watchable. As you can see based on my ping in the above picture, I get about 100ms to New York. Not bad, but also not ideal. With this in mind, if your lowest ping is 100, make sure to remember the fact that I could not stream at 3500kbps with non-freezing quality. I did not test 3400kbps or anything else in between, but the difference in quality between 3000 and 3500 is already very minimal.

Furthermore, make sure your audio bitrate is set to 192. When you decide your max bitrate, it does not take into account your audio. This means your actual total is 4192kbps if your bitrate is set to 4000. This comes back to the .5MB/s limit, as 4000 compared to 4192 does not make a huge difference, however if you set the audio to 256 or 320, you can start to see freezing occur. For some streamers, 256 is the preferred, so if you want to have marginally better audio quality, you may want to drop to 3900kbps.

Going back to testmy.net quickly. According to speedtest.net, this is my speed.

2577082202.png


This would allow for a little over 10,000kbps streaming, enough for almost any stream to be max quality at high resolution.

Now lets take a look at testmy.net

NGNsWJP.png


According to this, my sustained upload speed should only be about 3080kilobits per second. So why can I stream at 4000kbps? Whether or not testmy.net is more correct than speedtest.net, using speedtest is more than sufficient for the purposes of finding your streaming bitrate.

Below are my final OBS settings.

V5GKA3p.png



If everything is setup correctly, you should not have any more problems.

If you have any further problems regarding your stream freezing, don't hesitate to ask.


~~~~~Everything below is my original post~~~~~


I would like to reiterate my previous title which said I am dropping frames. OBS says I drop 0 frames on everything I stream, however my Twitch.tv stream has constant freezing.

I've been having this problem only starting about a week ago. Any time I try to use game capture (not to mention a lot of games aren't working when using it) I start to drop frames seemingly at random, but a consistent amount each time. I've tried almost every setting on/off with different combinations and even tried the settings that my friend uses and I still have the same problem. Here's a few speedtests of my connection:

227702182.png


2577082202.png


I am connected hardline to my router.

And here are my system specs.

lIPZZ3Y.png


My GPU is a HD 7950
u6iwCpx.png


Also, I was able to stream a few games earlier this month with almost no problem while having the same connection.

During my stream if I take a speed test it will always have the same readout with slight deviations of course in download/upload based on Comcast's current bandwidth output. Below is my current OBS settings while streaming desktop which has no problems with dropping frames.
Code:
=====Stream Start=====================================================================
  Multithreaded optimizations: On
  Base resolution: 1280x1024
  Output resolution: 1280x1024
------------------------------------------
Loading up D3D10...
Playback device Default
------------------------------------------
Using desktop audio input: Speakers (Realtek High Definition Audio)
------------------------------------------
Audio Encoding: AAC
    bitrate: 192
Using graphics capture
Using Monitor Capture
Using custom x264 settings: "vbvmaxrate=<6000>"
The custom x264 command 'vbvmaxrate=<6000>' failed
x264: using cpu capabilities: MMX2 SSE2Fast SSSE3 FastShuffle SSE4.2 AVX
x264: profile High, level 4.2
------------------------------------------
Video Encoding: x264
    fps: 60
    width: 1280, height: 1024
    preset: veryfast
    CBR: no
    CFR: no
    max bitrate: 6000
    buffer size: 6000
    quality: 10
------------------------------------------
Syncing audio to video time
Using RTMP service: Twitch / Justin.tv
  Server selection: rtmp://live-jfk.justin.tv/app
bufferTime: 2245, outputRateWindowTime: 1000, dropThreshold: 2745
Total frames rendered: 1876, number of frames that lagged: 1876 (100.00%) (it's okay for some frames to lag)
RTMPPublisher::SocketLoop: Aborting due to bStopping
Number of b-frames dropped: 0 (0%), Number of p-frames dropped: 0 (0%), Total 0 (0%)
x264: frame I:8     Avg QP:21.29  size:150134
x264: frame P:536   Avg QP:25.62  size:  6041
x264: frame B:1295  Avg QP:30.82  size:   356
x264: consecutive B-frames:  5.0%  2.8%  1.1% 91.0%
x264: mb I  I16..4: 53.0%  8.6% 38.3%
x264: mb P  I16..4:  4.7%  0.4%  0.8%  P16..4:  2.3%  0.6%  0.4%  0.0%  0.0%    skip:90.8%
x264: mb B  I16..4:  0.4%  0.0%  0.0%  B16..8:  0.4%  0.1%  0.0%  direct: 0.2%  skip:98.8%  L0:40.4% L1:38.6% BI:21.1%
x264: 8x8 transform intra:6.8% inter:30.7%
x264: coded y,uvDC,uvAC intra: 24.5% 11.5% 8.8% inter: 0.8% 0.3% 0.1%
x264: i16 v,h,dc,p: 57% 42%  1%  0%
x264: i8 v,h,dc,ddl,ddr,vr,hd,vl,hu: 25% 36% 33%  1%  1%  1%  1%  1%  2%
x264: i4 v,h,dc,ddl,ddr,vr,hd,vl,hu: 31% 39% 14%  2%  3%  3%  3%  2%  4%
x264: i8c dc,h,v,p: 77% 17%  5%  0%
x264: Weighted P-Frames: Y:0.0% UV:0.0%
x264: kb/s:621.56
=====Stream End=======================================================================

Now here's my average game capture stream.
Code:
=====Stream Start=====================================================================
  Multithreaded optimizations: On
  Base resolution: 1280x1024
  Output resolution: 1280x1024
------------------------------------------
Loading up D3D10...
Playback device Default
------------------------------------------
Using desktop audio input: Speakers (Realtek High Definition Audio)
------------------------------------------
Audio Encoding: AAC
    bitrate: 192
Using graphics capture
Using Window Capture
Using custom x264 settings: "vbvmaxrate=<4800>"
The custom x264 command 'vbvmaxrate=<4800>' failed
x264: using cpu capabilities: MMX2 SSE2Fast SSSE3 FastShuffle SSE4.2 AVX
x264: profile High, level 4.2
------------------------------------------
Video Encoding: x264
    fps: 60
    width: 1280, height: 1024
    preset: veryfast
    CBR: no
    CFR: no
    max bitrate: 4800
    buffer size: 4800
    quality: 10
------------------------------------------
Syncing audio to video time
SharedTexCapture hooked
SharedTexCapture hooked
Using RTMP service: Twitch / Justin.tv
  Server selection: rtmp://live-jfk.justin.tv/app
bufferTime: 2028, outputRateWindowTime: 1000, dropThreshold: 2528
SharedTexCapture hooked
SharedTexCapture hooked
RTMPPublisher::BufferedSend: Socket buffer is full (636386 / 638976 bytes), waiting to send 4097 bytes
RTMPPublisher::BufferedSend: Socket buffer is full (636386 / 638976 bytes), waiting to send 4097 bytes
RTMPPublisher::BufferedSend: Socket buffer is full (635126 / 638976 bytes), waiting to send 4097 bytes
RTMPPublisher::BufferedSend: Socket buffer is full (635126 / 638976 bytes), waiting to send 4097 bytes
SharedTexCapture hooked
SharedTexCapture hooked
SharedTexCapture hooked
SharedTexCapture hooked
RTMPPublisher::BufferedSend: Socket buffer is full (638315 / 638976 bytes), waiting to send 1248 bytes
RTMPPublisher::BufferedSend: Socket buffer is full (638315 / 638976 bytes), waiting to send 1248 bytes
RTMPPublisher::BufferedSend: Socket buffer is full (635294 / 638976 bytes), waiting to send 4097 bytes
RTMPPublisher::BufferedSend: Socket buffer is full (635294 / 638976 bytes), waiting to send 4097 bytes
RTMPPublisher::BufferedSend: Socket buffer is full (638634 / 638976 bytes), waiting to send 678 bytes
RTMPPublisher::BufferedSend: Socket buffer is full (638634 / 638976 bytes), waiting to send 678 bytes
RTMPPublisher::BufferedSend: Socket buffer is full (637335 / 638976 bytes), waiting to send 4097 bytes
RTMPPublisher::BufferedSend: Socket buffer is full (638569 / 638976 bytes), waiting to send 4097 bytes
RTMPPublisher::BufferedSend: Socket buffer is full (637377 / 638976 bytes), waiting to send 4097 bytes
RTMPPublisher::BufferedSend: Socket buffer is full (637348 / 638976 bytes), waiting to send 4097 bytes
RTMPPublisher::BufferedSend: Socket buffer is full (638473 / 638976 bytes), waiting to send 643 bytes
RTMPPublisher::BufferedSend: Socket buffer is full (638618 / 638976 bytes), waiting to send 4097 bytes
RTMPPublisher::BufferedSend: Socket buffer is full (638248 / 638976 bytes), waiting to send 3657 bytes
RTMPPublisher::BufferedSend: Socket buffer is full (638248 / 638976 bytes), waiting to send 3657 bytes
RTMPPublisher::BufferedSend: Socket buffer is full (636597 / 638976 bytes), waiting to send 4104 bytes
RTMPPublisher::BufferedSend: Socket buffer is full (637265 / 638976 bytes), waiting to send 4097 bytes
RTMPPublisher::BufferedSend: Socket buffer is full (638425 / 638976 bytes), waiting to send 4104 bytes
RTMPPublisher::BufferedSend: Socket buffer is full (635936 / 638976 bytes), waiting to send 4097 bytes

~~~~~~~~~~~~~~~~~~~~~~~~~~(excluding a lot of lines to shorten this)~~~~~~~~~~~~~~~~~~~~~~~~~

RTMPPublisher::BufferedSend: Socket buffer is full (638802 / 638976 bytes), waiting to send 533 bytes
RTMPPublisher::BufferedSend: Socket buffer is full (638598 / 638976 bytes), waiting to send 3737 bytes
RTMPPublisher::BufferedSend: Socket buffer is full (638598 / 638976 bytes), waiting to send 3737 bytes
RTMPPublisher::BufferedSend: Socket buffer is full (636087 / 638976 bytes), waiting to send 4104 bytes
SharedTexCapture hooked
Total frames rendered: 158498, number of frames that lagged: 9035 (5.70%) (it's okay for some frames to lag)
RTMPPublisher::SocketLoop: Aborting due to bStopping
Number of b-frames dropped: 9978 (6.3%), Number of p-frames dropped: 8933 (5.6%), Total 18911 (12%)
x264: frame I:1180  Avg QP:22.72  size: 49325
x264: frame P:68296 Avg QP:24.83  size: 10563
x264: frame B:88968 Avg QP:26.15  size:  1855
x264: consecutive B-frames: 19.0% 14.5% 11.5% 54.9%
x264: mb I  I16..4: 32.8% 51.9% 15.3%
x264: mb P  I16..4:  9.7% 10.4%  0.4%  P16..4: 19.1%  6.5%  1.9%  0.0%  0.0%    skip:52.2%
x264: mb B  I16..4:  0.7%  0.4%  0.0%  B16..8:  8.0%  1.6%  0.1%  direct: 1.0%  skip:88.0%  L0:41.2% L1:53.7% BI: 5.1%
x264: 8x8 transform intra:49.9% inter:37.8%
x264: coded y,uvDC,uvAC intra: 32.2% 17.6% 4.2% inter: 3.0% 2.4% 0.2%
x264: i16 v,h,dc,p: 44% 28% 20%  8%
x264: i8 v,h,dc,ddl,ddr,vr,hd,vl,hu: 20% 21% 33%  4%  4%  4%  5%  4%  5%
x264: i4 v,h,dc,ddl,ddr,vr,hd,vl,hu: 22% 23% 19%  6%  7%  6%  7%  5%  6%
x264: i8c dc,h,v,p: 72% 14% 13%  1%
x264: Weighted P-Frames: Y:2.4% UV:1.3%
x264: kb/s:2700.12
=====Stream End=======================================================================

As you can see, RTMPPublisher::BufferedSend: Socket buffer is full shows up multiple times. I deleted most of them because the log is extremely long. If there is any known solution to this socket buffer full problem, I believe it would solve my problem.

Any help solving this would be appreciated.
 

R1CH

Forum Admin
Developer
Re: Constant Frame Drops on Stable Connection

Try this: Drop your bitrate to 3500, turn off forced audio sync, remove your custom x264 settings and enable CBR. Try switching servers if lag persists.

The reason your desktop doesn't lag is because it's not moving, thus not generating any large packets.
 

bananaa101

New Member
Re: Constant Frame Drops on Stable Connection

Thanks, R1CH. I believe the main problem was the forced audio sync. I tested it with everything else the same and it worked without freezing. It's strange because the settings I listed here are basically identical to my friend's settings besides the bitrate and resolution and he streams perfectly fine. Forced audio sync must have some driver conflict involved.

On a tangentially related problem, I have still been having trouble game capturing with some games like RAGE, Red Faction: Guerilla, the COH games etc. which all do not work with game capture. Is this an AMD driver conflict or does OBS just not work properly with AMD in these games? I was able to play RAGE on my 9600gt and stream using game capture, however AMD refuses to work and makes the game crash instantly.
 

Krazy

Town drunk
Re: Constant Frame Drops on Stable Connection

If you haven't tried the latest test build, you should. There have been some changes to game capture that might help you out there.
 

Kayuo

New Member
Re: Constant Frame Drops on Stable Connection

Just to add on, you should try using http://testmy.net, some flash based tests can be inaccurate. I have comcast, my upload is usually around 6-7mb with testmy.net but 10mb on speedtest.net, so if your trying to do 6000kbps bit rate, i recommend making sure your results are accurate first.

References:
1. http://blog.twitch.tv/2013/03/quality-of-service-and-you-chasing-the-1080p-unicorn/ (Bottom paragraph)

2. from (0:37 - 3:01): http://youtube.com/watch?v=0xCl1BD88fw?t=14m53s
 

bananaa101

New Member
Re: Constant Frame Drops on Stable Connection

Kayuo said:
Just to add on, you should try using http://testmy.net, some flash based tests can be inaccurate. I have comcast, my upload is usually around 6-7mb with testmy.net but 10mb on speedtest.net, so if your trying to do 6000kbps bit rate, i recommend making sure your results are accurate first.
There is absolutely NO way this site is accurate for the purposes of your maximum upload/download. I get speeds that are literally a fraction of what they actually are when doing the tests on testmy.net. Just watching my netlimiter 3 program I can see it is only using utilizing .3MB/s when doing the upload test, and then the site says I get 3 Mbps 377 kB/s. When using a site like http://www.toledorocket.com/perftest/up ... select.asp and uploading a 25mb file, I get
Code:
 You uploaded 26,246,026 bytes in 20 seconds.  Your upload speed is 10,498 kbps.
And I am still having problems with obs constantly freezing even though it say I have 0 frames dropped now. I've tried both Twitch and Hashd.tv and both freeze the same.
 

Warchamp7

Forum Admin
Re: Constant Frame Drops on Stable Connection

testmynet gets a measurement of your sustained upload speed, not your maximum.

Just cause you can hit 23mbps max does not mean you can consistently sustain it.
 

bananaa101

New Member
Re: Constant Frame Drops on Stable Connection

Warchamp7 said:
testmynet gets a measurement of your sustained upload speed, not your maximum.

Just cause you can hit 23mbps max does not mean you can consistently sustain it.

...I download consistently between 4.6MB/s to 5MB/s on steam and any other website with that much bandwidth available. I can also upload a 25 megabyte video file to Youtube in under 20 seconds. Are you telling me the largest website used for streaming (aka Twitch) is limiting the amount I can consistently upload?

I also just recorded a 30 second fraps video which came out to be about 590MB and I am uploading it at 1.31MB/s which it has been staying at for over 3 minutes.
 

R1CH

Forum Admin
Developer
Keep in mind comcast temporarily boost your speeds for ~60 secs after starting transfers which makes speed tests unreliable.
 

bananaa101

New Member
R1CH said:
Keep in mind comcast temporarily boost your speeds for ~60 secs after starting transfers which makes speed tests unreliable.
So how is it possible that when uploading to youtube my sustained download speed stayed at over 1MB/s for over 3 minutes when uploading a 590MB file? Also, when choosing a small file to upload like 1.5MB from testmy.net it STILL only says 385 kB/s. Unless this site somehow "blocks" comcast upload speed boosting, I find it highly suspicious that youtube has no problems when I'm uploading.
 

hilalpro

Member
youtube (video uploading) is using a different protocol and running on a different port, their servers are also on a different ip range.
to confirm/deny the theory about comcast use this test viewtopic.php?f=18&t=2613 and see if the drops happen before/after the 60 seconds mark.
 

bananaa101

New Member
hilalpro said:
youtube (video uploading) is using a different protocol and running on a different port, their servers are also on a different ip range.
to confirm/deny the theory about comcast use this test viewtopic.php?f=18&t=2613 and see if the drops happen before/after the 60 seconds mark.
Thank you for this. It reinforced my previous theory that testmy.net is incorrect by about 700KB/s. I ran it for over 3 minutes and I stayed at 1MB/s. It dropped to .6MB/s once but quickly went back to above 1MB/s.

Not sure what the hell the point of testmy.net is but this worked flawlessly.
 
Top