From 1a77934531b0ddfc4392ccffbdde0058c2dbab68 Mon Sep 17 00:00:00 2001 From: David Robillard Date: Wed, 1 Aug 2007 04:42:09 +0000 Subject: Remove PostProcessor thread, post-process in main thread instead (solves scripting threading issues, and saves memory anyway). Revert saw_lp.ingen.ttl (version written by broken raptor committed by mistake). Working engine->script responses, nicer Python example. git-svn-id: http://svn.drobilla.net/lad/ingen@665 a436a847-0d15-0410-975c-d299462d15a1 --- src/libs/engine/PostProcessor.hpp | 18 ++++++++++++------ 1 file changed, 12 insertions(+), 6 deletions(-) (limited to 'src/libs/engine/PostProcessor.hpp') diff --git a/src/libs/engine/PostProcessor.hpp b/src/libs/engine/PostProcessor.hpp index b77bda6e..114a8bef 100644 --- a/src/libs/engine/PostProcessor.hpp +++ b/src/libs/engine/PostProcessor.hpp @@ -21,9 +21,9 @@ #include #include "types.hpp" #include -#include +//#include -namespace Raul { class Maid; } +//namespace Raul { class Maid; } namespace Ingen { @@ -36,20 +36,26 @@ class Event; * is realtime-safe), which signals the processing thread through a semaphore * to handle the event and pass it on to the Maid. * + * Update: This is all run from main_iteration now to solve scripting + * thread issues. Not sure if this is permanent/ideal or not... + * * \ingroup engine */ -class PostProcessor : public Raul::Slave +class PostProcessor //: public Raul::Slave { public: - PostProcessor(Raul::Maid& maid, size_t queue_size); + PostProcessor(/*Raul::Maid& maid, */size_t queue_size); /** Push an event on to the process queue, realtime-safe, not thread-safe. */ inline void push(Event* const ev) { _events.push(ev); } + /** Post-process and delete all pending events */ + void process(); + private: - Raul::Maid& _maid; + //Raul::Maid& _maid; Raul::SRSWQueue _events; - virtual void _whipped(); + //virtual void _whipped(); }; -- cgit v1.2.1