cap: Boolean;
farr: TBinary;
numRect: integer;
- numDescriptor: integer;
- numEntry: integer;
Fourier: TFourier;
{ private \90é\8c¾ }
procedure ShowToolbar(AShow: Boolean);
rr.Width := r.Width;
rr.Height := r.Height * rr.Width / r.Width;
end;
- //rr.Left := (Image2.Width - rr.Width) / 2;
- //rr.Top := (Image2.Height - rr.Height) / 2;
+ // rr.Left := (Image2.Width - rr.Width) / 2;
+ // rr.Top := (Image2.Height - rr.Height) / 2;
Image2.Canvas.FillRect(Image2.BoundsRect, 0, 0, [], 1.0);
Image2.Canvas.DrawBitmap(Image1.Bitmap, r, rr, 1.0);
break;
SetLength(id, Fourier.numEntry);
SetLength(estima, Fourier.numEntry);
test := TModel.Create;
- bnd:=TBoundary.Create;
+ bnd := TBoundary.Create;
try
n := bnd.numP;
for i := 0 to Fourier.numDescriptor - 1 do
estima[n] := Sqrt(dist);
end
else
- estima[n] := Fourier.Correlation(a, b, 4 * numDescriptor);
+ estima[n] := Fourier.Correlation(a, b, 4 * Fourier.numDescriptor);
end;
if RadioButton1.IsChecked = true then
Fourier.sortingSmall(estima, id, Fourier.numEntry)
k: integer;
fr, fi, ss, cc: Double;
begin
- for i := 0 to numEntry - 1 do
+ Fourier.numEntry := Edit5.Text.ToInteger;
+ for i := 0 to Fourier.numEntry - 1 do
begin
n := Fourier.boundary[i].numP;
for j := 0 to Fourier.numDescriptor - 1 do
with Fourier.boundary[i] do
begin
m := Count div n;
- X[n*m] := X[0];
- Y[n*m] := Y[0];
+ X[n * m] := X[0];
+ Y[n * m] := Y[0];
end;
for k := 0 to n - 1 do
begin
- fr := Fourier.boundary[i].X[k*m + 1] - Fourier.boundary[i].X[k*m];
- fi := Fourier.boundary[i].Y[k*m + 1] - Fourier.boundary[i].Y[k*m];
+ fr := Fourier.boundary[i].X[(k + 1) * m] - Fourier.boundary[i].X[k * m];
+ fi := Fourier.boundary[i].Y[(k + 1) * m] - Fourier.boundary[i].Y[k * m];
cc := cos(2 * pi * j * k / n);
ss := sin(2 * pi * j * k / n);
with Fourier.model[i] do
i := 10;
j := 10;
result := 0;
- boundary[0].Count:=0;
+ boundary[0].Count := 0;
while j < ny - 10 do
begin
if (f[i, j] = 1) and (id[i, j] = 0) then
if labelborder8(nx, ny, i, j, code, result, f, id) = true then
inc(result);
if result < numEntry then
- boundary[result].Count:=0
+ boundary[result].Count := 0
else
break;
end
Clear;
for i := 0 to Value - 1 do
begin
- FModels[i]:=TModel.Create;
+ FModels[i] := TModel.Create;
FBoundary[i] := TBoundary.Create;
end;
end;