Compare Image-Is there a faster way of doing this ?

Joined
Jan 10, 2007
Messages
43,898
Location
In The Machine
Is there a faster way of doing this ???

public
staticList CompareImage(Bitmap oldBitmap, Bitmap newBitmap)
{
List p = newList();
for (int x = 0; x < newBitmap.Width; x++)
for (int y = 0; y < newBitmap.Height; y++)
if (oldBitmap.GetPixel(x, y) != newBitmap.GetPixel(x, y))
p.Add(
newPixel(x, y, newBitmap.GetPixel(x, y)));
return p;
}

publicclassPixel
{
public Pixel(int X, int Y, Colour Colour)
{
this.X = X;
this.Y = Y;
this.Colour = Colour;
}
publicint X { get; set; }
publicint Y { get; set; }
publicColour Colour { get; set; }
}


More...

View All Our Microsoft Related Feeds
 
Back
Top