Convert the rest of the host modules for zero latency behaviour

Signed-off-by: falkTX <falktx@falktx.com>
This commit is contained in:
falkTX 2022-02-08 03:20:26 +00:00
parent 0000456cf5
commit deeecfd3ab
No known key found for this signature in database
GPG key ID: CDBAA37ABC74FBA0
10 changed files with 105 additions and 29 deletions

View file

@ -52,8 +52,7 @@
// known terminal modules
extern rack::plugin::Model* modelHostAudio2;
extern rack::plugin::Model* modelHostAudio8;
extern std::vector<rack::plugin::Model*> hostTerminalModels;
namespace rack {
@ -577,7 +576,7 @@ std::vector<int64_t> Engine::getModuleIds() {
static TerminalModule* asTerminalModule(Module* const module) {
const plugin::Model* const model = module->model;
if (model == modelHostAudio2 || model == modelHostAudio8)
if (std::find(hostTerminalModels.begin(), hostTerminalModels.end(), model) != hostTerminalModels.end())
return static_cast<TerminalModule*>(module);
return nullptr;
}