CPU spikes when using transition

BoxieG

New Member
Hi all!

Let me start off by saying English isn't my native tongue, so I might have issues getting my point across, or mess up with grammar.
Also, I'm a complete noob when it comes to tech, Apple and OBS :-)
I tried searching through the forum, but I couldn't find the real answer just yet. I do have a suspicion it's because of my system, but let's dig in.

I just started streaming through OBS, and created my own custom transition. Everything loaded up correctly, and when I'm testing* the transitions and scene selection in OBS offline, it's working smoothly - both audio and video of the transition look fine., with no weird CPU-spikes.

When I'm live, my transitions completely freeze up, both audio and video, and I'm experiencing CPU-spikes. For now, I've just turned them off, since I can't use them at all.

I'm experiencing these spikes even when the only program that is open is OBS - I've tried closing all other apps, except for OBS, but that doesn't make a difference.

Now, I've read in these forums that OBS isn't really working all that flawlessly with the M1 chip, so I guess that could already be the answer to my question. I'm contemplating on buying an extra computer to sort this issue, but before I dig deep into my savings, I would like to see what your thoughts are.

QUESTION:

- Is there something I can do on my end to make the CPU spike less and have the transition play smoothly?
- Or is this simply still an M1-thing, and do I have to wait for updates of OBS? (I think I read somewhere version 28 somewhere this year).


When OBS fires up, and is "idle", CPU is between 5.7% and 6.9%
Everything appears to be fine, even in recordings
Sources in the scene:
- Video capture (camera)
- Browser-capture to Streamelements (video overlay)
- Image (chat overlay)
- Browser-capture to Streamlabs (chat)

When offline but switching scenes WITH custom transition, CPU spikes between 15.7% and 23.3%
Audio sometimes glitches, but video appears to be fine
Sources in the second scene:
- Video capture (camera)
- Browser-capture to Streamelements (video overlay)
- Image (chat overlay)
- Browser-capture to Streamlabs (chat)
- Display capture (desktop)

When ONLINE (streaming) and switching scenes WITH custom transition, CPU spikes between 60% and 70%
Audio AND video of transition completely distort/stutter/glitch/freeze up, and entire streams drops frames for a couple of seconds.
Sources in the second scene:
- Video capture (camera)
- Browser-capture to Streamelements (video overlay)
- Image (chat overlay)
- Browser-capture to Streamlabs (chat)
- Display capture (desktop)

The stinger is a 4 second long clip I created in Davinci Resolve (using all the right settings, but obviously could post them if needed), and converted through Shutter Encoder to a VP9 webm-file of 2,9MB.

My system:
Macbook Pro (13-inch, M1, 2020)
Chip Apple M1
Memory 16GB

OBS-version: 27.2.4 (64bit)

If there's anything that I should have mentioned or left out, please let me know. Help me, help you, helping me :-)

Thanks a bunch in advance!

Cheers, Boxie
 

Nass86

Member
You need to add a Log file to this but as this has happened to me, I fixed it by:

1. Shortening the Fade if there is one. Ie. 1200ms reduced to 300ms is less work
2. Priming the MacBook for OBS with extra settings listed here https://obsproject.com/forum/threads/camera-low-frame-rate.151157/#post-553007
3. Turning the x264 processing speed down (if it is on Fast go to Faster, or Super Fast etc - just go to the one above it and test it one at a time until it works)

I also had success changing the Transition to something that looks great but happens to be less demanding.

Good luck!
 
Hi all!

Let me start off by saying English isn't my native tongue, so I might have issues getting my point across, or mess up with grammar.
Also, I'm a complete noob when it comes to tech, Apple and OBS :-)
I tried searching through the forum, but I couldn't find the real answer just yet. I do have a suspicion it's because of my system, but let's dig in.

I just started streaming through OBS, and created my own custom transition. Everything loaded up correctly, and when I'm testing* the transitions and scene selection in OBS offline, it's working smoothly - both audio and video of the transition look fine., with no weird CPU-spikes.

When I'm live, my transitions completely freeze up, both audio and video, and I'm experiencing CPU-spikes. For now, I've just turned them off, since I can't use them at all.

I'm experiencing these spikes even when the only program that is open is OBS - I've tried closing all other apps, except for OBS, but that doesn't make a difference.

Now, I've read in these forums that OBS isn't really working all that flawlessly with the M1 chip, so I guess that could already be the answer to my question. I'm contemplating on buying an extra computer to sort this issue, but before I dig deep into my savings, I would like to see what your thoughts are.

QUESTION:

- Is there something I can do on my end to make the CPU spike less and have the transition play smoothly?
- Or is this simply still an M1-thing, and do I have to wait for updates of OBS? (I think I read somewhere version 28 somewhere this year).


When OBS fires up, and is "idle", CPU is between 5.7% and 6.9%
Everything appears to be fine, even in recordings
Sources in the scene:
- Video capture (camera)
- Browser-capture to Streamelements (video overlay)
- Image (chat overlay)
- Browser-capture to Streamlabs (chat)

When offline but switching scenes WITH custom transition, CPU spikes between 15.7% and 23.3%
Audio sometimes glitches, but video appears to be fine
Sources in the second scene:
- Video capture (camera)
- Browser-capture to Streamelements (video overlay)
- Image (chat overlay)
- Browser-capture to Streamlabs (chat)
- Display capture (desktop)

When ONLINE (streaming) and switching scenes WITH custom transition, CPU spikes between 60% and 70%
Audio AND video of transition completely distort/stutter/glitch/freeze up, and entire streams drops frames for a couple of seconds.
Sources in the second scene:
- Video capture (camera)
- Browser-capture to Streamelements (video overlay)
- Image (chat overlay)
- Browser-capture to Streamlabs (chat)
- Display capture (desktop)

The stinger is a 4 second long clip I created in Davinci Resolve (using all the right settings, but obviously could post them if needed), and converted through Shutter Encoder to a VP9 webm-file of 2,9MB.

My system:
Macbook Pro (13-inch, M1, 2020)
Chip Apple M1
Memory 16GB

OBS-version: 27.2.4 (64bit)

If there's anything that I should have mentioned or left out, please let me know. Help me, help you, helping me :-)

Thanks a bunch in advance!

Cheers, Boxie

Don't feel bad, I have a Mac Studio Ultra and see the same issues:
A couple things. if you are reusing images between scenes, set them up so they are not unloaded. The same goes with Browser Objects (I use multiple browsers for adding guests into my livestream. If you are capturing the desktop, set it up in one scene and reuse it throughout your project. The above issues were the main reason I was seeing frame rate hit on scene display.

From a dev perspective, It looks like there is an issue in OBS that pauses rendering until assets are loaded rather than an asynchronous technique to bring them in as they are loaded. etc.
 

BoxieG

New Member
Don't feel bad, I have a Mac Studio Ultra and see the same issues:
A couple things. if you are reusing images between scenes, set them up so they are not unloaded. The same goes with Browser Objects (I use multiple browsers for adding guests into my livestream. If you are capturing the desktop, set it up in one scene and reuse it throughout your project. The above issues were the main reason I was seeing frame rate hit on scene display.

From a dev perspective, It looks like there is an issue in OBS that pauses rendering until assets are loaded rather than an asynchronous technique to bring them in as they are loaded. etc.
"Good" to hear I'm not the only one with the same issues haha!

Quick question: what do you mean with "if you are reusing images between scenes, set them up so they are not unloaded"?
 

BoxieG

New Member
You need to add a Log file to this but as this has happened to me, I fixed it by:

1. Shortening the Fade if there is one. Ie. 1200ms reduced to 300ms is less work
2. Priming the MacBook for OBS with extra settings listed here https://obsproject.com/forum/threads/camera-low-frame-rate.151157/#post-553007
3. Turning the x264 processing speed down (if it is on Fast go to Faster, or Super Fast etc - just go to the one above it and test it one at a time until it works)

I also had success changing the Transition to something that looks great but happens to be less demanding.

Good luck!
Thanks for your reply!

- Would adding a log file still be relevant for me to post it, as I haven't used the transition in the past 12 hrs of streaming? The issue only happens when streaming, not when recording.
- My stinger transition is indeed a long one (4 seconds), but I thought that was possible as I'm seeing other streaming using such long ones. I'll see what I can do to make it a shorter one, and see if that changes anything.
- I'll also have a look at the link you posted, much appreciated!
- I think that's already set to UltraFast (or whatever the highest is) but that didn't make a difference so far.

Thanks, I'll go check things out, and in the meantime I'll await the 28 version for Mac eagerly :-)

If anything here helped, I'll let everyone know.
 

Nass86

Member
Great. Also try Hardware Encloding instead of x264, not promising but it might change things up.
 
Top