예제 #1
0
        private void OpenToolStripMenuItem_Click(object sender, EventArgs e)
        {
            OpenFileDialog diag = new OpenFileDialog();

            if (diag.ShowDialog() == DialogResult.OK)
            {
                MyGraph.ClearElements();

                m_imagePath = diag.FileName;

                Image img = Image.FromFile(diag.FileName);
                PreviewPicturebox.Image = img;

                AddElement(new InputNode(img, MyGraph));
                AddElement(new OutputNode(MyGraph));
            }
        }