diff options
-rw-r--r-- | alc/backends/wasapi.cpp | 5 | ||||
-rw-r--r-- | alc/converter.cpp | 2 | ||||
-rw-r--r-- | alc/converter.h | 4 |
3 files changed, 6 insertions, 5 deletions
diff --git a/alc/backends/wasapi.cpp b/alc/backends/wasapi.cpp index 55c95146..806db122 100644 --- a/alc/backends/wasapi.cpp +++ b/alc/backends/wasapi.cpp @@ -1565,8 +1565,9 @@ HRESULT WasapiCapture::resetProxy() if(mDevice->Frequency != OutputType.Format.nSamplesPerSec || mDevice->FmtType != srcType) { - mSampleConv = CreateSampleConverter(srcType, mDevice->FmtType, mDevice->channelsFromFmt(), - OutputType.Format.nSamplesPerSec, mDevice->Frequency, BSinc24Resampler); + mSampleConv = CreateSampleConverter(srcType, mDevice->FmtType, + static_cast<ALuint>(mDevice->channelsFromFmt()), OutputType.Format.nSamplesPerSec, + mDevice->Frequency, BSinc24Resampler); if(!mSampleConv) { ERR("Failed to create converter for %s format, dst: %s %uhz, src: %s %luhz\n", diff --git a/alc/converter.cpp b/alc/converter.cpp index 58b59179..faf24948 100644 --- a/alc/converter.cpp +++ b/alc/converter.cpp @@ -144,7 +144,7 @@ void Stereo2Mono(ALfloat *RESTRICT dst, const void *src, const size_t frames) no } // namespace SampleConverterPtr CreateSampleConverter(DevFmtType srcType, DevFmtType dstType, size_t numchans, - ALsizei srcRate, ALsizei dstRate, Resampler resampler) + ALuint srcRate, ALuint dstRate, Resampler resampler) { if(numchans < 1 || srcRate < 1 || dstRate < 1) return nullptr; diff --git a/alc/converter.h b/alc/converter.h index 46e57f10..8a7b6f5f 100644 --- a/alc/converter.h +++ b/alc/converter.h @@ -43,8 +43,8 @@ struct SampleConverter { }; using SampleConverterPtr = std::unique_ptr<SampleConverter>; -SampleConverterPtr CreateSampleConverter(DevFmtType srcType, DevFmtType dstType, ALsizei numchans, - ALsizei srcRate, ALsizei dstRate, Resampler resampler); +SampleConverterPtr CreateSampleConverter(DevFmtType srcType, DevFmtType dstType, size_t numchans, + ALuint srcRate, ALuint dstRate, Resampler resampler); struct ChannelConverter { |