コード例 #1
0
        public Bitmap setImage()
        {
            var Canvas = new Bitmap(Width, Height);
            var e = new ProgressingEventArgs();



            for (int i = 0; i < Height; i++)
            {
                double Y = getY(i);
                for (int j = 0; j < Width; j++)
                {
                    double X = getX(j);

                    Canvas.SetPixel(j, i, getColor(X, Y));

                    e.Percent = 100 * (i * Height + j) / (Height * Width);
                    Progressing(this, e);
                }





            }


            e.Percent = 100;
            Progressing(this, e);
            return Canvas;
        }
コード例 #2
0
 void mandelbrot_Progressing(object sender, ProgressingEventArgs e)
 {
     this.progressBar1.Value = e.Percent;
 }