예제 #1
0
        void MnuFishEyeClick(object sender, System.EventArgs e)
        {
        	if (this.selectedImage == null)
                return;

            frmFE bfDLG = new frmFE();
            bfDLG.Curvature = Effects.curvature;
            DialogResult result = bfDLG.ShowDialog();

            if (result == DialogResult.OK)
            {
            	Effects.curvature = bfDLG.Curvature;
            	
            	Bitmap oldImg = this.SelectedImage;            
            	this.selectedImage = Effects.FishEye(this.SelectedImage);

                oldImg.Dispose();
            	
                this.picBoxMain.Invalidate();
                bfDLG.Dispose();
                // Gargabge Collection
                System.GC.Collect();
            }
        }
예제 #2
0
        private void btnFishEye_Click(object sender, EventArgs e)
        {
            frmFE bf = new frmFE();          

            DialogResult res = bf.ShowDialog();
            Application.DoEvents();

            if (res != DialogResult.OK)
                return;

            Application.DoEvents();

            if (Program.Photo != null)
            {
                try
                {
                    undoHelper.FishEyeCurvature = Effects2.curvature;
                    Effects2.curvature = bf.Curvature;

                    FilterEffects();

                }
                catch { }
            }
        }