Question / Help "Phantom" frame drops while streaming/recording

Laerx

New Member
Not sure how to describe this and can't find much on the forums about it. It is an intermittent issue and I don't change any settings between its occurrences.

Most games stream and record perfectly well but a handful of games I sometimes cannot do because of some sort of phantom performance drops. I've experienced this in Grim Dawn and Overwatch from recent memory. What I mean is any performance monitor utilized (built-in game monitors, Steam FPS display, Fraps, etc) will show a continuous FPS between the stream being on or off, with the occasional negligible dip (~92fps to ~80fps), but the actual gameplay is horrendously below the displayed FPS and feels like it's dropping or skipping frames rather than displaying them. I call this a phantom performance drop because there's no actual hit to my PC's performance or temperatures; when this happens I can fullscreen the OBS preview window on my second monitor and see the game playing at the full, real FPS that the game is actually running at. Similarly, when I hit record the game immediately feels like I'm playing at 30fps or below yet if I stop the recording and then go watch it, the video plays at the actual captured framerate.

So it's playing and capturing at the actual displayed framerate yet while I'm playing the game it feels like something much worse. Included is a log from a brief 40s recording I did today.

http://pastebin.com/raw/fegs7ARi
 

Boildown

Active Member
05:38:31: Total frames encoded: 7651, total frames duplicated: 1716 (22.43%)
05:38:31: Total frames rendered: 6876, number of late frames: 795 (11.56%) (it's okay for some frames to be late)

So your CPU is just bogged down unbelievably bad, at least as far as OBS is concerned. For a good looking video, duplicated frames needs to be less than 1% (as a rule of thumb at least), and yours is at 22%. You need to decrease your encode settings a lot. Change your preset to Super or Ultra Fast, change the FPS to 30 or 20 instead of 60, and/or decrease the resolution by increasing the downscale.

I'm guessing there's some fighting between OBS and the game you're playing, and occasionally OBS wins and it lags out your game, but mostly Overwatch/Grim Down wins and lags out OBS. In any case you need to decrease your OBS settings.
 

Laerx

New Member
Thanks for the help. Lowering to 30fps made a slight improvement but my duplicated frames were still around 13%. Changing the encoding to superfast brought that down to 2.86%. A few questions for my curiosity, though:

-Do you have any idea why a specific handful of games would have such a conflict with OBS that I'd need to reduce my encoding quality to retain comparable performance with every other game--specifically given that the problem games aren't any more taxing on my hardware than the ones that have no issues streaming at 60fps?
-Why would the recordings themselves still capture the full 60fps with no problems in video playback while the gameplay itself suffers so?
-With more intensive encoding causing CPU bogging, shouldn't my CPU's load reflect a maxing of resources? i.e. my CPU while just playing the game is experiencing about a 35-50% load, which marginally increases to about a 40-60% while streaming under the new encoding settings. But with the original encoding at veryfast @60fps, my CPU's only showing an ~8% increase in load. Are those specific games and/or OBS not utilizing all available cores or is my CPU throttling itself for temperature control? Under the same circumstances in all 3 tests in the Overwatch training area the core temps all sat at a stable 58-62C, which is what it seems to be at whenever any game is running, stream or no, so throttling may be likely.
-Interestingly, while the FPS is at 60, changing the encoding to superfast or ultrafast has no impact on frame duplication or late frames and today they're actually worse at 42% and 55%, respectively. What's going on here that's so different from changing this setting at 30fps?

Update: officially clueless.

I changed my settings back to their originals (720p, 60fps, veryfast encoding) and ticked my webcam's capture resolution down from 720p to 480p and now everything captures flawlessly. I'm duplicating 2.84% and my late frames are well below 1%. Not sure how that little quality reduction in a webcam has that big of an impact but I'll take it
 
Last edited:

Boildown

Active Member
Hmm so I didn't see any mention of a web cam in the logs posted, but its good that you found it.

Not really sure on the other parts, but it seems that other games are more or less successful at competing for CPU time vs OBS. And some games just aren't multithreaded enough for it to even matter how hard they "fight" for their cycles... an older game that only uses 2 cores max is going to have all the other cores free for OBS to use. While a modern-coded game built to generate more threads to utilize multi-core CPUs is going to conflict more with OBS, which needs to have unused CPU time to run. And then there's Windows in the mix with its (dubious) ability to divy up threads appropriately between all the applications asking for them. But I only have theorycrafting and generalities, not specifics. You can change how hard OBS "fights" for CPU time with the setting at Settings > Advanced > Process Priority Class, by the way.
 

Laerx

New Member
Good to know. I'll fiddle with the priority class if anything else seems to bog down. Thanks again.
 
Top