aboutsummaryrefslogtreecommitdiffstats
path: root/alc/backends/winmm.cpp
diff options
context:
space:
mode:
authorChris Robinson <[email protected]>2019-09-22 21:27:10 -0700
committerChris Robinson <[email protected]>2019-09-22 21:27:10 -0700
commit61ffa23e44c0e4ad9bdc99b1cf6e7ab7d36eb1c1 (patch)
tree4f416686d17507767f8d51ac8d86d50b7fb1704a /alc/backends/winmm.cpp
parent24db8a3f4bdbd787c23ac6e2ec78c2bafed81f1f (diff)
Fix a couple more conversion warnings
Diffstat (limited to 'alc/backends/winmm.cpp')
-rw-r--r--alc/backends/winmm.cpp12
1 files changed, 6 insertions, 6 deletions
diff --git a/alc/backends/winmm.cpp b/alc/backends/winmm.cpp
index 41c110d7..d58fa959 100644
--- a/alc/backends/winmm.cpp
+++ b/alc/backends/winmm.cpp
@@ -138,7 +138,7 @@ struct WinMMPlayback final : public BackendBase {
std::atomic<ALuint> mWritable{0u};
al::semaphore mSem;
- int mIdx{0};
+ ALuint mIdx{0u};
std::array<WAVEHDR,4> mWaveBuffer{};
HWAVEOUT mOutHdl{nullptr};
@@ -195,7 +195,7 @@ FORCE_ALIGN int WinMMPlayback::mixerProc()
continue;
}
- int widx{mIdx};
+ size_t widx{mIdx};
do {
WAVEHDR &waveHdr = mWaveBuffer[widx];
widx = (widx+1) % mWaveBuffer.size();
@@ -204,7 +204,7 @@ FORCE_ALIGN int WinMMPlayback::mixerProc()
mWritable.fetch_sub(1, std::memory_order_acq_rel);
waveOutWrite(mOutHdl, &waveHdr, sizeof(WAVEHDR));
} while(--todo);
- mIdx = widx;
+ mIdx = static_cast<ALuint>(widx);
}
unlock();
@@ -381,7 +381,7 @@ struct WinMMCapture final : public BackendBase {
std::atomic<ALuint> mReadable{0u};
al::semaphore mSem;
- int mIdx{0};
+ ALuint mIdx{0};
std::array<WAVEHDR,4> mWaveBuffer{};
HWAVEIN mInHdl{nullptr};
@@ -439,7 +439,7 @@ int WinMMCapture::captureProc()
continue;
}
- int widx{mIdx};
+ size_t widx{mIdx};
do {
WAVEHDR &waveHdr = mWaveBuffer[widx];
widx = (widx+1) % mWaveBuffer.size();
@@ -448,7 +448,7 @@ int WinMMCapture::captureProc()
mReadable.fetch_sub(1, std::memory_order_acq_rel);
waveInAddBuffer(mInHdl, &waveHdr, sizeof(WAVEHDR));
} while(--todo);
- mIdx = widx;
+ mIdx = static_cast<ALuint>(widx);
}
unlock();