public MemoryToTextureRenderer(FileStreamVlcNode vvvvNode, int slice, char group, DoubleMemoryBuffer doubleMemoryBuffer) { this.group = group; this.slice = slice; this.doubleBuffer = doubleMemoryBuffer; this.parent = vvvvNode; device2DoubleTexture = new Dictionary <Device, DoubleTexture>( ); //We will subscribe to the event fired by DoubleMemoryBuffer doubleBuffer.Toggle += new DoubleMemoryBuffer.ToggleHandler(DoubleBufferChanged); textureNeedsResizingOnEvaluate = true; memoryToTextureRendererBusyMutex = new Mutex( ); //CREATE A THREAD THAT WILL TRY TO LOAD NEW FILES ETC. //when signalled by evaluateEventWaitHandle updateTextureEventWaitHandle = new EventWaitHandle(false, EventResetMode.AutoReset); updateTextureStopThreadWaitHandle = new EventWaitHandle(false, EventResetMode.AutoReset); updateTextureThread = new Thread(new ThreadStart(UpdateTexture_ThreadProc)); initialized = true; updateTextureThread.Start( ); }