SubmarinerApp / Submariner

A Subsonic client for macOS
https://submarinerapp.com
BSD 3-Clause "New" or "Revised" License
141 stars 4 forks source link

Reduce progress update interval to 0.1 #169

Closed skyline75489 closed 1 year ago

skyline75489 commented 1 year ago

This significantly reduces CPU usage.

skyline75489 commented 1 year ago

I'm using an old MBP (Early 2015) and I noticed very high CPU usage while playing music (~50%). With this PR, the CPU usage drops to ~7% while playing.

NattyNarwhal commented 1 year ago

Looks like I ran the numbers before a year ago almost to this day. I reverted back to the 0.01 NSTimer instead of using KVO, but did notice that a 0.1 timer took less CPU time. I just don't remember why I didn't apply that change afterward.

NattyNarwhal commented 1 year ago

Oh, I think it might have been the sliders not adjusting constantly smoothly. I don't think it matters that much though.