1
0
mirror of https://github.com/moparisthebest/Simba synced 2025-02-16 07:10:10 -05:00

Mainly warning fixes.

git-svn-id: http://www.villavu.com/repositories/merlijn/mufasa@344 3f818213-9676-44b0-a9b4-5e4c4e03d09d
This commit is contained in:
Wizzup? 2009-12-26 15:01:19 +00:00
parent ebbd4dcb5c
commit ffcb20146b
6 changed files with 17 additions and 13 deletions

View File

@ -70,7 +70,7 @@ var
begin
if CurrThread.Client.MDTM.GetDTM(DTM, temp) then
Result := CurrThread.Client.MFinder.FindDTMsRotated(temp, Points, x1, y1, x2, y2,
sAngle, eAngle, aStep, aFound)
sAngle, eAngle, aStep, aFound, 0)
else
Result := False;
end;

View File

@ -403,7 +403,7 @@ end;
procedure TMufasaBitmap.LoadFromRawImage(RawImage: TRawImage);
var
x,y,v: integer;
x,y: integer;
_24_old_p: PByte;
rs,gs,bs:byte;
data: PRGB32;
@ -484,7 +484,6 @@ begin
end;
end;
end;
writeln('done');
end;
procedure TMufasaBitmap.LoadFromTBitmap(bmp: TBitmap);

View File

@ -37,7 +37,8 @@ Procedure PrintpDTM(tDTM : pDTM);
procedure initdtm(out d: pdtm; len: integer);
function ValidMainPointBox(var dtm: pDTM; const x1, y1, x2, y2: Integer): TBox;
function ValidMainPointBoxRotated(var dtm: pDTM; const x1, y1, x2, y2: Integer): TBox;
function ValidMainPointBoxRotated(var dtm: pDTM; const x1, y1, x2, y2: Integer;
sAngle, eAngle, aStep: Extended): TBox;
function DTMConsistent(var dtm: pdtm): boolean;
procedure NormalizeDTM(var dtm: pdtm);
@ -227,7 +228,8 @@ begin
Result.y2 := y2 - b.y2;
end;
Function ValidMainPointBoxRotated(var dtm: pDTM; const x1, y1, x2, y2: Integer): TBox;
Function ValidMainPointBoxRotated(var dtm: pDTM; const x1, y1, x2, y2: Integer;
sAngle, eAngle, aStep: Extended): TBox;
begin

View File

@ -84,7 +84,7 @@ type
function FindDTM(DTM: pDTM; out x, y: Integer; x1, y1, x2, y2: Integer): Boolean;
function FindDTMs(DTM: pDTM; out Points: TPointArray; x1, y1, x2, y2, maxToFind: Integer): Boolean;
function FindDTMRotated(DTM: pDTM; out x, y: Integer; x1, y1, x2, y2: Integer; sAngle, eAngle, aStep: Extended; out aFound: Extended): Boolean;
function FindDTMsRotated(DTM: pDTM; out Points: TPointArray; x1, y1, x2, y2: Integer; sAngle, eAngle, aStep: Extended; out aFound: T2DExtendedArray): Boolean;
function FindDTMsRotated(DTM: pDTM; out Points: TPointArray; x1, y1, x2, y2: Integer; sAngle, eAngle, aStep: Extended; out aFound: T2DExtendedArray; maxToFind: Integer): Boolean;
protected
@ -1796,6 +1796,8 @@ var
C: Array of Integer;
// Bitwise
// TODO: Change to record. One that indicates if there is a match at bit i
// and one that indicates it has already been matched at bit i...
b: Array of Array of Integer;
// bounds
@ -1845,7 +1847,9 @@ begin
setlength(b[i], H + 1);
// does setlength init already? if it doesn't, do we want to init here?
// or do we want to init in the loop, as we loop over every b anyway?
//FillChar(b[i][0], SizeOf(Integer) * H, 0);
// init
FillChar(b[i][0], SizeOf(Integer) * H, 0);
end;
// C = DTM.C
@ -1909,7 +1913,7 @@ begin
raise Exception.CreateFmt('Not done yet!', []);
end;
function TMFinder.FindDTMsRotated(DTM: pDTM; out Points: TPointArray; x1, y1, x2, y2: Integer; sAngle, eAngle, aStep: Extended; out aFound: T2DExtendedArray): Boolean;
function TMFinder.FindDTMsRotated(DTM: pDTM; out Points: TPointArray; x1, y1, x2, y2: Integer; sAngle, eAngle, aStep: Extended; out aFound: T2DExtendedArray; maxToFind: Integer): Boolean;
begin
// Don't forget to pre calculate the rotated points at the start.

View File

@ -37,7 +37,7 @@ uses
bitmaps,
LCLIntf // for ReleaseDC and such
{$IFDEF LINUX}, xlib, x, xutil, ctypes{$ENDIF};
{$IFDEF LINUX}, xlib, x, xutil{$ENDIF};
type
@ -158,7 +158,6 @@ type
implementation
uses
Client, // For the Client Class
windowutil, // For utilities such as XImageToRawImage
GraphType // For TRawImage
;
@ -407,7 +406,7 @@ end;
function TMWindow.Freeze: Boolean;
var
w,h,x,y : integer;
w,h : integer;
PtrReturn : TRetData;
begin
if Self.FreezeState then

View File

@ -18,7 +18,7 @@ uses
Procedure XImageToRawImage(XImg: PXImage; Var RawImage: TRawImage);
function MufasaXErrorHandler(para1:PDisplay; para2:PXErrorEvent):cint;cdecl;
{$ENDIF}
Procedure ArrDataToRawImage(Ptr: PRGB32; Size: TPoint; Var RawImage: TRawImage);
Procedure ArrDataToRawImage(Ptr: PRGB32; Size: TPoint; out RawImage: TRawImage);
implementation
@ -89,7 +89,7 @@ End;
// Needs more fixing. We need to either copy the memory ourself, or somehow
// find a TRawImage feature to skip X bytes after X bytes read. (Most likely a
// feature)
Procedure ArrDataToRawImage(Ptr: PRGB32; Size: TPoint; Var RawImage: TRawImage);
Procedure ArrDataToRawImage(Ptr: PRGB32; Size: TPoint; out RawImage: TRawImage);
Begin
RawImage.Init; { Calls raw.Description.Init as well }