private void RenderForm_FormClosed(object sender, FormClosedEventArgs e) { RenderTarget.Dispose(); foreach (var item in LayerList) { item.Value.Dispose(); } FactoryWrite.Dispose(); Factory.Dispose(); }
private void RenderForm_FormClosed(object sender, FormClosedEventArgs e) { if (streamProc != null) { streamProc.Exited -= Process_Exited; streamProc.Kill(); } RenderTarget.Dispose(); layerClock.Dispose(); layerBack.Dispose(); FactoryWrite.Dispose(); Factory.Dispose(); }