Index: /experimental/Threading/Threading/IGConnector.cpp
===================================================================
--- /experimental/Threading/Threading/IGConnector.cpp	(revision 425)
+++ /experimental/Threading/Threading/IGConnector.cpp	(revision 425)
@@ -0,0 +1,23 @@
+#include "IGConnector.h"
+
+#include <osg/Notify>
+#include "ThreadedWorker.h"
+
+
+IGConnector::IGConnector()
+{
+}
+
+IGConnector::~IGConnector()
+{
+}
+
+void IGConnector::operator()(ThreadedWorker* threadObject)
+{
+	OSG_ALWAYS<<"IGConnector running: ID "<<threadObject->getThreadId()<<std::endl;
+
+	// Place Holder
+	for(int i=0;i<100;i++)
+		OSG_ALWAYS<<"";
+
+}
Index: /experimental/Threading/Threading/IGConnector.h
===================================================================
--- /experimental/Threading/Threading/IGConnector.h	(revision 425)
+++ /experimental/Threading/Threading/IGConnector.h	(revision 425)
@@ -0,0 +1,11 @@
+#pragma once
+#include "ThreadWorkerBase.h"
+
+class IGConnector :	public ThreadWorkerBase
+{
+public:
+	IGConnector();
+	~IGConnector();
+
+	void operator() (ThreadedWorker* threadObject);
+};
Index: /experimental/Threading/Threading/SimHost.cpp
===================================================================
--- /experimental/Threading/Threading/SimHost.cpp	(revision 424)
+++ /experimental/Threading/Threading/SimHost.cpp	(revision 425)
@@ -33,10 +33,13 @@
 	OpenThreads::Barrier syncBarrier;
 
-	// Create ChannelWorkers
-	OSG_ALWAYS<<"Creating ChannelWorkers..."<<std::endl;
+	// Create IG Connectors
+	OSG_ALWAYS<<"Creating IG Connectors..."<<std::endl;
 	for(int i=0; i<numThreads-1; ++i)
 	{
-		osg::ref_ptr<ChannelWorker> worker = new ChannelWorker();
-		_channelWorker.push_back(worker);
+		osg::ref_ptr<ThreadedWorker> threadObject = new ThreadedWorker();
+		osg::ref_ptr<IGConnector> IGCon = new IGConnector();
+		threadObject->setThreadWorker(IGCon);
+		_threadObjects.push_back(threadObject);
+		_IGConnectors.push_back(IGCon);
 	}
 	OSG_ALWAYS<<"...done."<<std::endl;
@@ -55,22 +58,21 @@
 {
 	// Launch threads
-    for(int i=0;i<static_cast<int>(_channelWorker.size());++i)
+    for(int i=0;i<static_cast<int>(_threadObjects.size());++i)
 	{
 		int status;
 		
 		//thread->setStackSize(1024*256);
-		status = _channelWorker[i]->start();
+		status = _threadObjects[i]->start();
 		assert(status == 0);
 	}
 
 	// Do something in the main thread
-	for(int i=0;i<10000000;i++)
-		OSG_ALWAYS<<"";
+		for(int i=0;i<10000000;i++)	OSG_ALWAYS<<"";
 	
 	// Signal threads to finish
-    for(int i=0;i<static_cast<int>(_channelWorker.size());++i)
+    for(int i=0;i<static_cast<int>(_threadObjects.size());++i)
 	{
-		//_channelWorker[i]->setDone(true);	// non blocking
-		_channelWorker[i]->cancel();	// Blocking
+		//_threadObjects[i]->setDone(true);	// non blocking
+		_threadObjects[i]->cancel();	// Blocking
 	}
 
@@ -78,4 +80,3 @@
 		OSG_ALWAYS<<"";
 
-	//syncBarrier.block(numThreads);  // Block until all threads are ready
 }
Index: /experimental/Threading/Threading/SimHost.h
===================================================================
--- /experimental/Threading/Threading/SimHost.h	(revision 424)
+++ /experimental/Threading/Threading/SimHost.h	(revision 425)
@@ -5,5 +5,6 @@
 #include <osg/ref_ptr>
 
-#include "ChannelWorker.h"
+#include "ThreadedWorker.h"
+#include "IGConnector.h"
 
 
@@ -18,5 +19,6 @@
 
 private:
-	std::vector<osg::ref_ptr<ChannelWorker> > _channelWorker;
+	std::vector<osg::ref_ptr<IGConnector> > _IGConnectors;
+	std::vector<osg::ref_ptr<ThreadedWorker> > _threadObjects;
 
 };
Index: /experimental/Threading/Threading/ThreadWorkerBase.h
===================================================================
--- /experimental/Threading/Threading/ThreadWorkerBase.h	(revision 424)
+++ /experimental/Threading/Threading/ThreadWorkerBase.h	(revision 425)
@@ -1,3 +1,7 @@
 #pragma once
+#include <osg/Referenced>
+
+
+class ThreadedWorker;
 
 /**
@@ -5,12 +9,12 @@
  * 
  * Just overload the operator() with your code you want to execute threaded in a loop.
- * Each execution will be completed by the thread, if the thread is cancels during a run, the cancelation will be postponed until the execution  of the functor is completed.
+ * Each execution will be completed by the thread, if the thread is set as done/canceled during a run, the cancelation will be postponed until the execution of the functor is completed.
  * 
- * Note: This functor will be executed in a loop until the thread is canceled or the parameter done is set to true.
+ * Note: This functor will be executed in a loop until the thread is canceled or set as done=true.
  * 
  * @author Torben Dannhauer
  * @date  Okt 2012
  */ 
-class ThreadWorkerBase
+class ThreadWorkerBase : public osg::Referenced
 {
 public:
@@ -18,4 +22,7 @@
 	virtual ~ThreadWorkerBase() ;
 
-	void operator() (bool& _threadDone);
+	virtual void operator() (ThreadedWorker* threadObject) = 0;
+
+
+
 };
Index: /experimental/Threading/Threading/ThreadedWorker.cpp
===================================================================
--- /experimental/Threading/Threading/ThreadedWorker.cpp	(revision 424)
+++ /experimental/Threading/Threading/ThreadedWorker.cpp	(revision 425)
@@ -1,4 +1,5 @@
 #include "ThreadedWorker.h"
 #include <osg/Notify>
+#include <OpenThreads/ScopedLock>
 
 
@@ -19,14 +20,12 @@
 
 	// Do the work
-	int i=0;
 	do
 	{
-		OSG_ALWAYS<<"ID "<<getThreadId()<<" :: itr "<<i++<<std::endl;
+		OpenThreads::ScopedLock<OpenThreads::Mutex> lock(_threadWorkerMutex);
 
-		// Place Holder
-		for(int i=0;i<100;i++)
-		OSG_ALWAYS<<"";
-
-	} while (!testCancel() && !_done);	// repeat as long it is canceld or set as Done
+		if( _threadWorker.valid() )
+			(*_threadWorker)(this);
+		
+	} while (_threadWorker!=NULL && !testCancel() && !_done);	// repeat as long as a functor is set and it is not canceled or set as Done
 }
 
@@ -60,2 +59,9 @@
     return 0;
 }
+
+void ThreadedWorker::setThreadWorker( ThreadWorkerBase* tworker)
+{
+	OpenThreads::ScopedLock<OpenThreads::Mutex> lock(_threadWorkerMutex);
+
+	_threadWorker = tworker;
+}
Index: /experimental/Threading/Threading/ThreadedWorker.h
===================================================================
--- /experimental/Threading/Threading/ThreadedWorker.h	(revision 424)
+++ /experimental/Threading/Threading/ThreadedWorker.h	(revision 425)
@@ -2,8 +2,19 @@
 
 #include <osg/Referenced>
+#include <osg/ref_ptr>
 #include <OpenThreads/Thread>
+#include <OpenThreads/Mutex>
+
+#include "ThreadWorkerBase.h"
+
 
 /**
  * \brief This class is a Thread Object which allows to create Functors and attach them to this thread object.
+ * 
+ * Subclass ThreadWorkerBase to implement your own functor to execute your custom code threaded.
+ * 
+ * Use setDone(true) to shut down the thread nonblocking, or call cancel() to shut down the thread blocking (both called from outside of the workerthread).
+ * Inside the workerthread's functor, you can set the functor parameter done=true to shutdown the thread after the current execution.
+ *
  * 
  * @author Torben Dannhauer
@@ -18,8 +29,13 @@
 	virtual int cancel();
 	
-	void setDone(bool done);	// sinbgals the thread to stop but returns immediately. Use cancel if you want to wait blocking until the thread is canceled.
+	void setDone(bool done);	// signals the thread to stop but returns immediately. Use cancel if you want to wait blocking until the thread is canceled.
 	bool getDone() const { return _done; }	
+
+	void setThreadWorker( ThreadWorkerBase* tworker);	// This function sets the functor which should be executed threaded. Set NULL to remove the current functor and cancel the thread.
+	ThreadWorkerBase* getCurrentThreadWorker()		{return(_threadWorker);};
 
 private:
 	bool _done;
+	osg::ref_ptr<ThreadWorkerBase> _threadWorker;
+	OpenThreads::Mutex _threadWorkerMutex;	// Ensures the functor is not replacable while it is executed
 };
Index: /experimental/Threading/Threading/Threading.vcproj
===================================================================
--- /experimental/Threading/Threading/Threading.vcproj	(revision 424)
+++ /experimental/Threading/Threading/Threading.vcproj	(revision 425)
@@ -182,4 +182,8 @@
 			>
 			<File
+				RelativePath=".\IGConnector.cpp"
+				>
+			</File>
+			<File
 				RelativePath=".\main.cpp"
 				>
@@ -204,4 +208,8 @@
 			>
 			<File
+				RelativePath=".\IGConnector.h"
+				>
+			</File>
+			<File
 				RelativePath=".\SimHost.h"
 				>
Index: /experimental/Threading/Threading/main.cpp
===================================================================
--- /experimental/Threading/Threading/main.cpp	(revision 424)
+++ /experimental/Threading/Threading/main.cpp	(revision 425)
@@ -9,9 +9,6 @@
 int main( int argc, char **argv )
 {
-
 	// Create osgVisual::SimHost
-	OSG_ALWAYS<<"Creating SimHost..."<<std::endl;
 	osg::ref_ptr<SimHost> simulationHost = new SimHost();
-	OSG_ALWAYS<<"...done."<<std::endl;
 
 	//Start it
