diff options
| author | Stephen Sinclair <radarsat1@gmail.com> | 2017-10-06 16:48:03 -0300 |
|---|---|---|
| committer | Stephen Sinclair <radarsat1@gmail.com> | 2017-10-06 16:48:03 -0300 |
| commit | c3a34072169f06936a335715f735869e0363b025 (patch) | |
| tree | 424c23bb97dc1d8b1aad8e2dc6ab967bb74dc8ed /RtAudio.cpp | |
| parent | 77bc4543d84686e768522ab803e03a99cc104326 (diff) | |
Use "using namespace std" for roundf in previous patch.
Similar to edb4ec67. The reason is because std::roundf causes errors
in some compilers even with cmath, yet roundf by itself should exist
in math.h. TODO: Switch to std::round when moving to C++11.
Diffstat (limited to 'RtAudio.cpp')
| -rw-r--r-- | RtAudio.cpp | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/RtAudio.cpp b/RtAudio.cpp index b29cae9..b00b803 100644 --- a/RtAudio.cpp +++ b/RtAudio.cpp @@ -4974,7 +4974,8 @@ void RtApiWasapi::wasapiThread() } if ( stream_.mode == INPUT ) { - convBuffSize = ( size_t ) std::roundf( stream_.bufferSize * captureSrRatio ) * stream_.nDeviceChannels[INPUT] * formatBytes( stream_.deviceFormat[INPUT] ); + using namespace std; // for roundf + convBuffSize = ( size_t ) roundf( stream_.bufferSize * captureSrRatio ) * stream_.nDeviceChannels[INPUT] * formatBytes( stream_.deviceFormat[INPUT] ); deviceBuffSize = stream_.bufferSize * stream_.nDeviceChannels[INPUT] * formatBytes( stream_.deviceFormat[INPUT] ); } else if ( stream_.mode == OUTPUT ) { |
