diff --git a/CMakeLists.txt b/CMakeLists.txt index 4a20f53..01f92a3 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -423,6 +423,12 @@ IF (MSVC) set(CMAKE_CREATE_WIN32_EXE "/SUBSYSTEM:WINDOWS /ENTRY:\"mainCRTStartup\"") ENDIF(MSVC) +IF (APPLE) + ADD_DEFINITIONS( + -DHAVE_TYPE_TRAITS=1 + ) +ENDIF(APPLE) + IF (APPLE AND BUNDLE_APP) PROJECT(CubicSDR) SET(MACOSX_BUNDLE_BUNDLE_NAME CubicSDR) @@ -431,7 +437,6 @@ IF (APPLE AND BUNDLE_APP) -std=c++0x -pthread -D_OSX_APP_ - -DHAVE_TYPE_TRAITS=1 -mmacosx-version-min=10.9 ) diff --git a/src/demod/DemodulatorThread.cpp b/src/demod/DemodulatorThread.cpp index 2ed31b0..e1274e2 100644 --- a/src/demod/DemodulatorThread.cpp +++ b/src/demod/DemodulatorThread.cpp @@ -320,8 +320,8 @@ void DemodulatorThread::run() { } ati->data.resize(numAudioWritten * 2); for (int i = 0; i < numAudioWritten; i++) { - ati->data[i * 2] = (*inputData)[i].real; - ati->data[i * 2 + 1] = (*inputData)[i].imag; + ati->data[i * 2] = (*inputData)[i].imag; + ati->data[i * 2 + 1] = (*inputData)[i].real; } } else if (stereo && inp->sampleRate >= 100000) { ati->channels = 2;