Exemple #1
0
 private void buttonSolve_Click(object sender, EventArgs e)
 {
     Stopwatch timer = new Stopwatch();
     timer.Start();
         ConvexHullSolver convexHullSolver = new ConvexHullSolver();
         convexHullSolver.Solve(m_g, m_pointList);
     timer.Stop();
     statusLabel.Text = "Done.  Time taken: " + timer.Elapsed;
 }
Exemple #2
0
 private void buttonSolve_Click(object sender, EventArgs e)
 {
     Stopwatch timer = new Stopwatch();
     timer.Start();
         ConvexHullSolver convexHullSolver = new ConvexHullSolver(m_g, pictureBoxView);
         ConvexHullSolver.drawPolygon(convexHullSolver.Solve(m_pointList));
         pictureBoxView.Refresh();
     timer.Stop();
     statusLabel.Text = "Done.  Time taken: " + timer.Elapsed;
 }
Exemple #3
0
        private void buttonSolve_Click(object sender, EventArgs e)
        {
            Stopwatch timer = new Stopwatch();

            timer.Start();
            ConvexHullSolver convexHullSolver = new ConvexHullSolver();

            convexHullSolver.Solve(m_g, m_pointList);
            timer.Stop();
            statusLabel.Text = "Done.  Time taken: " + timer.Elapsed;
        }
Exemple #4
0
        private void buttonSolve_Click(object sender, EventArgs e)
        {
            Stopwatch timer = new Stopwatch();

            timer.Start();
            ConvexHullSolver convexHullSolver = new ConvexHullSolver(m_g, pictureBoxView, Convert.ToInt32(pause.Text));

            convexHullSolver.Solve(m_pointList);
            pictureBoxView.Refresh();
            timer.Stop();
            statusLabel.Text = "Done.  Time taken: " + timer.Elapsed;
        }
Exemple #5
0
        private void buttonSolve_Click(object sender, EventArgs e)
        {
            Stopwatch timer = new Stopwatch();

            timer.Start();
            ConvexHullSolver convexHullSolver = new ConvexHullSolver();

            convexHullSolver.Solve(m_g, m_pointList, pictureBoxView);
            timer.Stop();
            statusLabel.Text = "Done.  Time taken: " + timer.Elapsed;
            pictureBoxView.Refresh();
            timeElapsed = timer.ElapsedMilliseconds;
        }
        private void buttonSolve_Click(object sender, EventArgs e)
        {
            Stopwatch timer = new Stopwatch();
            timer.Start();
            ConvexHullSolver convexHullSolver = new ConvexHullSolver(m_g, pictureBoxView);
            // Insert the points
            /*
            List<PointF> customPoints = new List<PointF>();
            customPoints.Add(new PointF(0F, 20F));
            customPoints.Add(new PointF(10F, 40F));
            customPoints.Add(new PointF(20F, 2F));
            customPoints.Add(new PointF(50F, 0F));
            customPoints.Add(new PointF(70F, 20F));
            customPoints.Add(new PointF(60F, 40F));
            m_pointList = customPoints;
             */
            convexHullSolver.Solve(m_pointList);
            pictureBoxView.Refresh();
            timer.Stop();
            statusLabel.Text = "Done.  Time taken: " + timer.Elapsed;

        }