Understanding how JUCE handles multiple threads
JUCE includes a cross-platform interface to operating system threads using its
Thread class. There are also classes that help with synchronizing inter-thread communication, notably the
CriticalSection class, the
WaitableEvent class, and the
Atomic template classes (for example,
Atomic<int>). Writing multithreaded applications is inherently challenging and it is beyond the scope of this book to serve as an introduction. However, JUCE does make the processes of writing multithreaded applications a little easier. One way in which this is achieved is through providing a consistent interface on all platforms. JUCE will also raise assertions if you do certain things that are likely to lead to some of the ...