You cannot select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

25 lines
619 B
C#

using System;
using System.Collections.Generic;
using System.Text;
using System.Drawing;
namespace Quilt
{
class Program
{
static void Main(string[] args)
{
Bitmap bm = new Bitmap("d:\\quilt.bmp");
Random ran = new Random();
for(int i = 0; i<bm.Width; i++)
{
for(int j=0; j<bm.Height; j++)
{
bm.SetPixel(i, j, Color.FromArgb(ran.Next(0, 255), ran.Next(0, 255), ran.Next(0, 255)));
}
}
bm.Save("d:\\quilt2.bmp");
}
}
}