private void InterpolationCompletedBG(object sender, RunWorkerCompletedEventArgs e) { DateTime ta = DateTime.Now; InterpolationResult r = (InterpolationResult)e.Result; DateTime tb = r.TimeStarted; TimeSpan delta = ta.Subtract(tb); this.pictureBox1.Image = r.Image; MessageBox.Show("Time required: " + delta.TotalMilliseconds + " ms."); }
private void RawVcdCpuNoInterpolationBG(object sender, DoWorkEventArgs e) { DateTime tb = DateTime.Now; PixelTypeCount count = new PixelTypeCount(); Image result = libRaw.RawVcdCpuSingleFrame(count); BackgroundWorker bw = (BackgroundWorker)sender; InterpolationResult ir = new InterpolationResult(); ir.Image = result; ir.TimeStarted = tb; e.Result = ir; }
private void RawVcdCpuNoInterpolationBG(object sender, DoWorkEventArgs e) { DateTime tb = DateTime.Now; PixelTypeCount count = new PixelTypeCount(); Image result = libRaw.RawVcdCpuSingleFrame(count); BackgroundWorker bw = (BackgroundWorker)sender; InterpolationResult ir = new InterpolationResult(); ir.Image = result; ir.TimeStarted = tb; e.Result = ir; }