Hi,
I've been troubleshooting dropped frames pretty intensely for about a week now and I've tried everything such as rerouting coax around my house to improve signals to my modem, replacing all ethernet cables, swapping out the router, swapping out my network switch, changing bitrates, changing ingest servers, adjusting qos on my router, removing qos entirely, using different encoders such as QSV and NVENC instead of x264, and even going so far as to use OBS Classic and Streamlabs OBS just to see if i have the same issues. I also looked at this thread here: https://obsproject.com/forum/threads/dropped-frames-disconnecting-lag-read-this-first.8870/ which inspired some of these troubleshooting steps that Ive taken.
I have access to two PCS and I've tried a single PC setup with QSV, NVENC, and x264 as well as a dual PC setup both with an nginx-RTMP installation and then NDI source. None of these options helped me.
Long story short, the trouble remains, but I think I've found the problem and I know of possible solutions. I'm making this thread in hopes that I can find a solution that works for my situation.
What I found so far is that my dropped frames stem from the fact that OBS uses GPU for rendering the scene and resizing the video. I understand this is done because the GPU is more efficient than a CPU for doing such a task, but it presents a problem wherein my frames drop massively if my GPU is ever put at 100%. I can replicate this easily by starting a stream or a recording an then opening up any stressful game, such as GTAV, then doing something like looking at the grass to pin my gpu usage at 95%+. No matter what i'm using, be it x264, QSV, NVENC or NDI Source to my second PC, the dropped frames will happen immediately.
In order to solve this, I feel like I have three options that are as follows:
1. Defer scene rendering to CPU, removing the issue of dropped frames when the GPU hits 100%. This could be useful when I use NVENC to encode my stream so my CPU is not being stressed that much and there is available headroom on the CPU to perform the task.
2. Defer scene rendering to a secondary GPU. Same as above, but I feel like I could use my CPU's iGPU to render the scene rather than my primary GPU. OBS Classic had an option that looked like it would do this, but is unfortunately not supported anymore for obvious reasons. I'd like to try something like that in OBS Studio.
3. Buy a capture card. This would bypass the issue entirely because all the stream rendering and encoding would happen on my second PC. I could max out my gaming GPU usage without encountering dropped frames, but this is my least preferred option due to the cost of a capture card.
I do not feel I have enough C/C++ experience to dive into the source myself and rewrite it as I described in options 1 or 2 above, but I would love if there would be a way to do so. I'm fine with it even if I have to hard code a GPU hardware ID or string literal to select a secondary GPU for scene rendering, as this would at least give me something to work with.
I appreciate anyone's feedback and responses on this in advance, and I look forward to figuring out a solution that fits for me. Thank you all for your time.
I've been troubleshooting dropped frames pretty intensely for about a week now and I've tried everything such as rerouting coax around my house to improve signals to my modem, replacing all ethernet cables, swapping out the router, swapping out my network switch, changing bitrates, changing ingest servers, adjusting qos on my router, removing qos entirely, using different encoders such as QSV and NVENC instead of x264, and even going so far as to use OBS Classic and Streamlabs OBS just to see if i have the same issues. I also looked at this thread here: https://obsproject.com/forum/threads/dropped-frames-disconnecting-lag-read-this-first.8870/ which inspired some of these troubleshooting steps that Ive taken.
I have access to two PCS and I've tried a single PC setup with QSV, NVENC, and x264 as well as a dual PC setup both with an nginx-RTMP installation and then NDI source. None of these options helped me.
Long story short, the trouble remains, but I think I've found the problem and I know of possible solutions. I'm making this thread in hopes that I can find a solution that works for my situation.
What I found so far is that my dropped frames stem from the fact that OBS uses GPU for rendering the scene and resizing the video. I understand this is done because the GPU is more efficient than a CPU for doing such a task, but it presents a problem wherein my frames drop massively if my GPU is ever put at 100%. I can replicate this easily by starting a stream or a recording an then opening up any stressful game, such as GTAV, then doing something like looking at the grass to pin my gpu usage at 95%+. No matter what i'm using, be it x264, QSV, NVENC or NDI Source to my second PC, the dropped frames will happen immediately.
In order to solve this, I feel like I have three options that are as follows:
1. Defer scene rendering to CPU, removing the issue of dropped frames when the GPU hits 100%. This could be useful when I use NVENC to encode my stream so my CPU is not being stressed that much and there is available headroom on the CPU to perform the task.
2. Defer scene rendering to a secondary GPU. Same as above, but I feel like I could use my CPU's iGPU to render the scene rather than my primary GPU. OBS Classic had an option that looked like it would do this, but is unfortunately not supported anymore for obvious reasons. I'd like to try something like that in OBS Studio.
3. Buy a capture card. This would bypass the issue entirely because all the stream rendering and encoding would happen on my second PC. I could max out my gaming GPU usage without encountering dropped frames, but this is my least preferred option due to the cost of a capture card.
I do not feel I have enough C/C++ experience to dive into the source myself and rewrite it as I described in options 1 or 2 above, but I would love if there would be a way to do so. I'm fine with it even if I have to hard code a GPU hardware ID or string literal to select a secondary GPU for scene rendering, as this would at least give me something to work with.
I appreciate anyone's feedback and responses on this in advance, and I look forward to figuring out a solution that fits for me. Thank you all for your time.