![]() |
DSPatch
v.2.42
C++ Cross-Platform, Object-Oriented, Flow-Based Programming Library
|
System-wide DSPatch functionality. More...
#include <DSPatch.h>
Static Public Member Functions | |
static bool | IsThisGlobalCircuit (DspComponent *thisComponent) |
static bool | AddGlobalComponent (DspComponent *component, std::string componentName="") |
static void | RemoveGlobalComponent (DspComponent *component) |
static unsigned short | GetGlobalComponentCount () |
static void | StartGlobalAutoTick () |
static void | StopGlobalAutoTick () |
static void | SetGlobalThreadCount (unsigned short threadCount) |
static void | Finalize () |
System-wide DSPatch functionality.
At the core of the DSPatch framework is what's known as the "global circuit". The DSPatch class and hence, the global circuit provides a transparent workspace for "global scoped components" (components not within a DspCircuit) to benefit from circuit parallel processing. As it is not required that components be explicitly added to a DspCircuit in order to be routed etc., in order for these global scoped components to benefit from the multi threading associated with the circuit scheduler, they are automatically added to the DSPatch global circuit when parallel processing is required (i.e. StartAutoTick() is called). Although global circuit operations are automatic and transparent to the user, if required, the user is may set the number of threads used by the global circuit by calling SetGlobalThreadCount().
Lastly, the Finalize() method must be called on application exit in order for DSPatch to perform the necessary memory cleanup.