# Windows Audio CPU use

**URL:** <https://forum.juce.com/t/windows-audio-cpu-use/4605>\
**Category:** Windows\
**Created:** [December 4, 2009, 5:25pm UTC](https://forum.juce.com/t/windows-audio-cpu-use/4605 "2009-12-04T17:25:58Z")\
**Posts on this page:** 7\
**Page:** 1

<div class="post-metadata">

**Author:** ![PieterS](https://sea2.discourse-cdn.com/flex026/user_avatar/forum.juce.com/pieters/32/10588_2.png) [@PieterS](https://forum.juce.com/u/PieterS)\
**Post date:** [December 4, 2009, 5:25pm UTC](https://forum.juce.com/t/windows-audio-cpu-use/4605/1 "2009-12-04T17:25:58Z")

</div>

why is the new WASAPI interface much more CPU intensive than for example ASIO? Is there something i can do about it?

PieterS

---

<div class="post-metadata">

**Author:** ![jules](https://avatars.discourse-cdn.com/v4/letter/j/41988e/32.png) [@jules](https://forum.juce.com/u/jules)\
**Post date:** [December 4, 2009, 6:10pm UTC](https://forum.juce.com/t/windows-audio-cpu-use/4605/2 "2009-12-04T18:10:43Z")

</div>

I didn’t think it was noticably different. What kind of numbers are you talking about?

---

<div class="post-metadata">

**Author:** ![PieterS](https://sea2.discourse-cdn.com/flex026/user_avatar/forum.juce.com/pieters/32/10588_2.png) [@PieterS](https://forum.juce.com/u/PieterS)\
**Post date:** [December 4, 2009, 8:38pm UTC](https://forum.juce.com/t/windows-audio-cpu-use/4605/3 "2009-12-04T20:38:22Z")

</div>

I noticed by accident that the default setting (441 samples) runs fine, with 0% cpu load, but as soon as I raise the buffer setting to 1024 samples my CPU goes to 25% on a dual core 2.6GHz Pentium…

This is reproducible on your demo, in release mode too.

Maybe it’s my crappy soundcard on my development computer, just a realtek thing, don’t know.

PieterS

---

<div class="post-metadata">

**Author:** ![jules](https://avatars.discourse-cdn.com/v4/letter/j/41988e/32.png) [@jules](https://forum.juce.com/u/jules)\
**Post date:** [December 6, 2009, 12:56pm UTC](https://forum.juce.com/t/windows-audio-cpu-use/4605/4 "2009-12-06T12:56:23Z")

</div>

Well, the juce code doesn’t care what size the buffer is, so very unlikely that this is anything I can fix. It’s probably the driver - if its hardware is designed for 441 samples, then it might have to run some sort of software layer to deal with other buffer sizes, and who knows what that might involve.

But when you say “cpu”, what do you mean? If you just mean task manager, the numbers that it shows aren’t necessarily very meaningful. You’d need to really look closely at the thread level to actually know what’s going on.

---

<div class="post-metadata">

**Author:** ![PieterS](https://sea2.discourse-cdn.com/flex026/user_avatar/forum.juce.com/pieters/32/10588_2.png) [@PieterS](https://forum.juce.com/u/PieterS)\
**Post date:** [December 7, 2009, 11:19pm UTC](https://forum.juce.com/t/windows-audio-cpu-use/4605/5 "2009-12-07T23:19:00Z")

</div>

yes, it is the task manager I am talking about. Never mind, I think it might be the card driver too.

---

<div class="post-metadata">

**Author:** ![Pontus](https://sea2.discourse-cdn.com/flex026/user_avatar/forum.juce.com/pontus/32/416_2.png) [@Pontus](https://forum.juce.com/u/Pontus)\
**Post date:** [January 5, 2010, 8:47pm UTC](https://forum.juce.com/t/windows-audio-cpu-use/4605/6 "2010-01-05T20:47:40Z")

</div>

I had the exact same problem. I am using WASAPI on Win 7 and changed the buffer size of the AudioDeviceManager which resulted in the CPU going through the roof (one core running at 100%).

I just commented out the buffer size change and left it at the default and now everything is fine! Thanks for pointing out the solution!

---

<div class="post-metadata">

**Author:** ![jules](https://avatars.discourse-cdn.com/v4/letter/j/41988e/32.png) [@jules](https://forum.juce.com/u/jules)\
**Post date:** [May 12, 2017, 9:49am UTC](https://forum.juce.com/t/windows-audio-cpu-use/4605/7 "2017-05-12T09:49:37Z")

</div>

Closed on May 12, 2017, 9:49am UTC


