private void Render(ScreenWindow screenWindow) { if ((screenWindow != null) && (screenWindow.Handle != IntPtr.Zero)) { Image original = ScreenCapture.Capture3(screenWindow); if (original != null) { float num3 = original.Width * this.m_ImageScale; float num4 = original.Height * this.m_ImageScale; Bitmap bitmap = new Bitmap(original, new Size((int)num3, (int)num4)); //~ if (m_IsFramelessMode) { Bitmap orig = new Bitmap(original, new Size((int)num3, (int)num4)); ScreenCapture.ApplyChromaKey3(bitmap, m_ChromaColor); } //~ original.Dispose(); this.pictureBox.Image = bitmap; if (m_isImageFlipped) { this.pictureBox.Image.RotateFlip(RotateFlipType.RotateNoneFlipX); } else { this.pictureBox.Image.RotateFlip(RotateFlipType.RotateNoneFlipNone); } if (!(this.m_ImageScale == this.m_PreviousImageScale)) { this.AutoSizeWindow(new Rectangle(0, 0, (int)num3, (int)num4)); } } } if (this.m_IsRubberBandBoxBeingDragged) { this.DrawRubberBandBox(this.pictureBox, this.m_LastLocation); } GC.Collect(); }