From 29b42e6cf66ae944404890db0783f31ddd3f23c5 Mon Sep 17 00:00:00 2001 From: Jonathan Thomas Date: Sat, 30 Mar 2019 15:43:34 -0500 Subject: [PATCH] Init COM on thread (WASAPI won't work with libopenshot-audio without this line) --- .../modules/juce_audio_devices/native/juce_win32_WASAPI.cpp | 3 +++ 1 file changed, 3 insertions(+) diff --git a/JuceLibraryCode/modules/juce_audio_devices/native/juce_win32_WASAPI.cpp b/JuceLibraryCode/modules/juce_audio_devices/native/juce_win32_WASAPI.cpp index def3648..c6f3f0a 100644 --- a/JuceLibraryCode/modules/juce_audio_devices/native/juce_win32_WASAPI.cpp +++ b/JuceLibraryCode/modules/juce_audio_devices/native/juce_win32_WASAPI.cpp @@ -1572,6 +1572,9 @@ private: StringArray& outDeviceIds, StringArray& inDeviceIds) { + // Init COM on thread (WASAPI won't work with libopenshot-audio without this line) + CoInitialize(0); + if (enumerator == nullptr) { if (! check (enumerator.CoCreateInstance (__uuidof (MMDeviceEnumerator))))