From 34093b89423e7d195972e68676c73853228d35f6 Mon Sep 17 00:00:00 2001 From: David Robillard Date: Tue, 20 May 2008 05:21:43 +0000 Subject: Fix direct midi in -> midi out connections in root patch with plugins present. Fix Jack MIDI output. Attempted fixes for LV2 UI MIDI event writing, but.. still not working? git-svn-id: http://svn.drobilla.net/lad/ingen@1223 a436a847-0d15-0410-975c-d299462d15a1 --- src/libs/engine/PatchImpl.cpp | 24 +++++++++++++----------- 1 file changed, 13 insertions(+), 11 deletions(-) (limited to 'src/libs/engine/PatchImpl.cpp') diff --git a/src/libs/engine/PatchImpl.cpp b/src/libs/engine/PatchImpl.cpp index dba3d747..1625d1c3 100644 --- a/src/libs/engine/PatchImpl.cpp +++ b/src/libs/engine/PatchImpl.cpp @@ -34,12 +34,12 @@ namespace Ingen { PatchImpl::PatchImpl(Engine& engine, const string& path, uint32_t poly, PatchImpl* parent, SampleRate srate, size_t buffer_size, uint32_t internal_poly) -: NodeBase(new PatchPlugin("http://example.org/FIXME", "patch", "Ingen Patch"), - path, poly, parent, srate, buffer_size), - _engine(engine), - _internal_poly(internal_poly), - _compiled_patch(NULL), - _process(false) + : NodeBase(new PatchPlugin("http://example.org/FIXME", "patch", "Ingen Patch"), + path, poly, parent, srate, buffer_size) + , _engine(engine) + , _internal_poly(internal_poly) + , _compiled_patch(NULL) + , _process(false) { assert(internal_poly >= 1); } @@ -139,7 +139,7 @@ PatchImpl::apply_internal_poly(Raul::Maid& maid, uint32_t poly) void PatchImpl::process(ProcessContext& context) { - if (_compiled_patch == NULL || _compiled_patch->size() == 0 || !_process) + if (!_process) return; NodeBase::pre_process(context); @@ -152,10 +152,12 @@ PatchImpl::process(ProcessContext& context) << ((MidiBuffer*)_ports->at(i)->buffer(0))->event_count() << endl;*/ /* Run */ - if (_engine.process_slaves().size() > 0) - process_parallel(context); - else - process_single(context); + if (_compiled_patch && _compiled_patch->size() > 0) { + if (_engine.process_slaves().size() > 0) + process_parallel(context); + else + process_single(context); + } NodeBase::post_process(context); } -- cgit v1.2.1