Question / Help Lagging when recording Team Fortress 2, how to fix?

CharType

New Member
I get considerable lag whenever I try to record Team Fortress 2 with OBS. All the other games I have tried to record work fine. It works a bit better when I turn my audio redirect software off, but it's still fairly bad. The attached logs are where I was playing Team Fortress 2 and having problems with lag. The most recent session today is the one where I turned my audio redirect software off. Can anyone suggest a way to fix this problem? Thanks.
 

Attachments

  • 2019-12-24 23-43-17.txt
    13.5 KB · Views: 129
  • 2019-12-25 00-28-35.txt
    12.8 KB · Views: 27
  • 2019-12-26 20-37-12.txt
    6.6 KB · Views: 25

Narcogen

Active Member
Even with your low settings you're bumping up against the limit of what your GPU can do.

00:21:13.465: Output 'adv_file_output': Number of lagged frames due to rendering lag/stalls: 14 (0.4%)
23:50:32.536: Output 'adv_file_output': Number of lagged frames due to rendering lag/stalls: 12 (0.2%)


https://obsproject.com/wiki/GPU-overload-issues

Is there a reason you're recording in 16x10? I ask because while that may be your display's native resolution, nearly all platforms consider 16:9 standard, which means that in order to be presented, that image would either be stretched, cropped, or otherwise be modified to fit. You might shave some GPU usage by using 1280x720 instead if you can get the game to render in a resolution that is both acceptable for your viewing and records natively in 16:9 in OBS.
 

CharType

New Member
Ok, I think I understand the problem now, thanks. I'll see if I can turn down the game graphics and see if that helps with the GPU overload.

I'm not sure why you thought I was recording in 16x10, if it says I was somewhere then please point it out to me. From the log file it looks like I was recording in 1280x940, which is some weird ratio and I'm not sure why I was doing that. Anyway, I'll try changing it to 1280x720, or 16:9.
 

Narcogen

Active Member
That should be fine. The rest applies the same to any non-16:9 ratio; either the audience will see the adjustment, or you will.
 

CharType

New Member
I've been changing the settings, and I have another question. You said that I should try recording in 1280x720 if I can get the game to render in a 16x9 ratio. But I checked and Team Fortress 2 absolutely refuses to display a 16x9 ratio. It will only display 1280x800, at 16x10. Does that mean that I should also set my video settings to 1280x800 for best performance? Also should I use "fit to screen" under transform on the source? Again, thanks.
 

Narcogen

Active Member
That likely means that the game knows your display isn't 16x9 and so isn't offering those resolutions.

So one solution is to set your display to the resolution you want to record, but that's going to involve either black boxes or stretching and some reduction in fidelity.

You will get best visual display by playing and recording at the native display resolution because that involves no scaling, but the end result will need black bars or stretching to fill a 16x9 aspect ratio.

You might investigate the possibility of editing the game's config files to set it to a resolution the GUI is not offering you. That might give you either black bars or stretching, but you should be able to compensate for that in OBS by either cropping out the black bars, or using "stretch to fill" on the source in OBS to undo the stretch or squeeze.
 
Top