
12-12-2010
|
|
Registrado
|
|
Registrado: jul 2010
Posts: 8
Reputación: 0
|
|
Ahí lo hice, es una cosa de niños al final...
Código:
procedure TForm1.Button1Click(Sender: TObject);
var
e,I: Integer;
begin
igual := 0;
distinto := 0;
for I := 0 to Image1.Width-1 do
begin
for E := 0 to Image1.Height - 1 do
begin
if Image1.Picture.Bitmap.Canvas.Pixels[e,i] = Image2.Picture.Bitmap.Canvas.Pixels[e,i] then
igual := igual +1
else
distinto := distinto+1;
end;
end;
labelededit1.Text := IntToStr(igual);
labelededit2.Text := IntToStr(distinto);
end;
De ahí sale cuantos son iguales y cuantos no. Gracias!
|