double i = 0;
SolidBrush s = new SolidBrush(Color.Black);
private void timer1_Tick(object sender, EventArgs e)
{
Bitmap b = new Bitmap(pictureBox1.Image, pictureBox1.Size);
Graphics g = Graphics.FromImage(b);
i+=3;
g.SmoothingMode = System.Drawing.Drawing2D.SmoothingMode.AntiAlias;
g.DrawLine(new Pen(Brushes.Black),
float.Parse((Math.Cos(Math.PI * i / 180) * (b.Width / 20 + (i / 11)) + b.Width / 2).ToString()),
float.Parse((Math.Sin(Math.PI * i / 180) * (b.Width / 20 + (i / 11)) + b.Width / 2).ToString()),
float.Parse((Math.Cos(Math.PI * (i-1) / 180) * (b.Width / 20+((i-1)/11)) + b.Width / 2).ToString()),
float.Parse((Math.Sin(Math.PI * (i-1) / 180) * (b.Width / 20+((i-1)/11)) + b.Width / 2).ToString())
);
pictureBox1.Image = b;
this.Text = i.ToString();
if (i>=2660)
{
timer1.Enabled = false;
}
}
private void Form1_Load(object sender, EventArgs e)
{
Bitmap b = new Bitmap(pictureBox1.Width, pictureBox1.Height);
pictureBox1.Image = b;
}