diff options
| author | Jordan Woyak <jordan.woyak@gmail.com> | 2011-01-31 08:19:27 +0000 |
|---|---|---|
| committer | Jordan Woyak <jordan.woyak@gmail.com> | 2011-01-31 08:19:27 +0000 |
| commit | 1de40588acd0bfa6d49e3d94fef2cbd6dc09f6e5 (patch) | |
| tree | 93472097d7916eb4680f3b032286f729abdffd46 /Source/Core/AudioCommon/Src/DSoundStream.cpp | |
| parent | 67a4ac0bf67d9299fb19575ccf5fc2034a8da9fd (diff) | |
Eliminate some trampoline functions.
git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@7015 8ced0084-cf51-0410-be5f-012b33b47a6e
Diffstat (limited to 'Source/Core/AudioCommon/Src/DSoundStream.cpp')
| -rw-r--r-- | Source/Core/AudioCommon/Src/DSoundStream.cpp | 12 |
1 files changed, 5 insertions, 7 deletions
diff --git a/Source/Core/AudioCommon/Src/DSoundStream.cpp b/Source/Core/AudioCommon/Src/DSoundStream.cpp index 4823c46732..206685f707 100644 --- a/Source/Core/AudioCommon/Src/DSoundStream.cpp +++ b/Source/Core/AudioCommon/Src/DSoundStream.cpp @@ -15,9 +15,12 @@ // Official SVN repository and contact information can be found at // http://code.google.com/p/dolphin-emu/ -#include <windows.h> #include <cmath> +#include <functional> + +#include <windows.h> #include <dxerr.h> + #include "AudioCommon.h" #include "DSoundStream.h" @@ -91,11 +94,6 @@ bool DSound::WriteDataToBuffer(DWORD dwOffset, // Our own write } // The audio thread. -void soundThread(DSound* dsound) -{ - dsound->SoundLoop(); -} - void DSound::SoundLoop() { currentPos = 0; @@ -137,7 +135,7 @@ bool DSound::Start() dsBuffer->Lock(0, bufferSize, (void* *)&p1, &num1, 0, 0, 0); memset(p1, 0, num1); dsBuffer->Unlock(p1, num1, 0, 0); - thread = std::thread(soundThread, this); + thread = std::thread(std::mem_fun(&DSound::SoundLoop), this); return true; } |
