mirror of
https://github.com/moparisthebest/Simba
synced 2025-02-16 07:10:10 -05:00
More documentation changes + additions.
Mainly skeletons of all the functions without further explanation and examples.
This commit is contained in:
parent
bc7c429195
commit
47886fdf25
@ -16,3 +16,6 @@ default (Pascal) engine.
|
||||
scriptref/files.rst
|
||||
scriptref/ocr.rst
|
||||
scriptref/dtm.rst
|
||||
scriptref/window.rst
|
||||
scriptref/web.rst
|
||||
scriptref/bitmaps.rst
|
||||
|
414
Doc/sphinx/scriptref/bitmaps.rst
Normal file
414
Doc/sphinx/scriptref/bitmaps.rst
Normal file
@ -0,0 +1,414 @@
|
||||
|
||||
.. _scriptref_bitmaps:
|
||||
|
||||
Bitmaps
|
||||
=======
|
||||
|
||||
CreateBitmapString
|
||||
------------------
|
||||
|
||||
.. code-block:: pascal
|
||||
|
||||
function CreateBitmapString(bmp : integer) : string;
|
||||
|
||||
|
||||
GetMufasaBitmap
|
||||
---------------
|
||||
|
||||
.. code-block:: pascal
|
||||
|
||||
function GetMufasaBitmap(bmp : integer) : TMufasaBitmap;
|
||||
|
||||
|
||||
CreateBitmap
|
||||
------------
|
||||
|
||||
.. code-block:: pascal
|
||||
|
||||
function CreateBitmap(w,h :integer) : integer;
|
||||
|
||||
|
||||
FreeBitmap
|
||||
----------
|
||||
|
||||
.. code-block:: pascal
|
||||
|
||||
procedure FreeBitmap(Bmp : integer);
|
||||
|
||||
|
||||
SaveBitmap
|
||||
----------
|
||||
|
||||
.. code-block:: pascal
|
||||
|
||||
procedure SaveBitmap(Bmp : integer; path : string);
|
||||
|
||||
|
||||
BitmapFromString
|
||||
----------------
|
||||
|
||||
.. code-block:: pascal
|
||||
|
||||
function BitmapFromString(Width,Height : integer; Data : string): integer;
|
||||
|
||||
|
||||
LoadBitmap
|
||||
----------
|
||||
|
||||
.. code-block:: pascal
|
||||
|
||||
function LoadBitmap(Path : string) : integer;
|
||||
|
||||
|
||||
SetBitmapSize
|
||||
-------------
|
||||
|
||||
.. code-block:: pascal
|
||||
|
||||
procedure SetBitmapSize(Bmp,NewW,NewH : integer);
|
||||
|
||||
|
||||
GetBitmapSize
|
||||
-------------
|
||||
|
||||
.. code-block:: pascal
|
||||
|
||||
procedure GetBitmapSize(Bmp : integer; var BmpW,BmpH : integer);
|
||||
|
||||
|
||||
StretchBitmapResize
|
||||
-------------------
|
||||
|
||||
.. code-block:: pascal
|
||||
|
||||
procedure StretchBitmapResize(Bmp,NewW,NewH : integer);
|
||||
|
||||
|
||||
CreateMirroredBitmap
|
||||
--------------------
|
||||
|
||||
.. code-block:: pascal
|
||||
|
||||
function CreateMirroredBitmap(Bmp : integer) : integer;
|
||||
|
||||
|
||||
CreateMirroredBitmapEx
|
||||
----------------------
|
||||
|
||||
.. code-block:: pascal
|
||||
|
||||
function CreateMirroredBitmapEx(Bmp : integer; MirrorStyle : TBmpMirrorStyle) : integer;
|
||||
|
||||
|
||||
FastSetPixel
|
||||
------------
|
||||
|
||||
.. code-block:: pascal
|
||||
|
||||
procedure FastSetPixel(bmp,x,y : integer; Color : TColor);
|
||||
|
||||
|
||||
FastSetPixels
|
||||
-------------
|
||||
|
||||
.. code-block:: pascal
|
||||
|
||||
procedure FastSetPixels(bmp : integer; TPA : TPointArray; Colors : TIntegerArray);
|
||||
|
||||
|
||||
FastGetPixel
|
||||
------------
|
||||
|
||||
.. code-block:: pascal
|
||||
|
||||
function FastGetPixel(bmp, x,y : integer) : TColor;
|
||||
|
||||
|
||||
FastGetPixels
|
||||
-------------
|
||||
|
||||
.. code-block:: pascal
|
||||
|
||||
function FastGetPixels(Bmp : integer; TPA : TPointArray) : TIntegerArray;
|
||||
|
||||
|
||||
GetBitmapAreaColors
|
||||
-------------------
|
||||
|
||||
.. code-block:: pascal
|
||||
|
||||
function GetBitmapAreaColors(bmp,xs, ys, xe, ye: Integer): T2DIntegerArray;
|
||||
|
||||
|
||||
FastDrawClear
|
||||
-------------
|
||||
|
||||
.. code-block:: pascal
|
||||
|
||||
procedure FastDrawClear(bmp : integer; Color : TColor);
|
||||
|
||||
|
||||
FastDrawTransparent
|
||||
-------------------
|
||||
|
||||
.. code-block:: pascal
|
||||
|
||||
procedure FastDrawTransparent(x, y: Integer; SourceBitmap, TargetBitmap: Integer);
|
||||
|
||||
|
||||
SetTransparentColor
|
||||
-------------------
|
||||
|
||||
.. code-block:: pascal
|
||||
|
||||
procedure SetTransparentColor(bmp : integer; Color : TColor);
|
||||
|
||||
|
||||
GetTransparentColor
|
||||
-------------------
|
||||
|
||||
.. code-block:: pascal
|
||||
|
||||
function GetTransparentColor(bmp: integer) : TColor;
|
||||
|
||||
|
||||
FastReplaceColor
|
||||
----------------
|
||||
|
||||
.. code-block:: pascal
|
||||
|
||||
procedure FastReplaceColor(Bmp : integer; OldColor,NewColor : TColor);
|
||||
|
||||
|
||||
CopyClientToBitmap
|
||||
------------------
|
||||
|
||||
.. code-block:: pascal
|
||||
|
||||
procedure CopyClientToBitmap(bmp, xs, ys, xe, ye: Integer);
|
||||
|
||||
|
||||
BitmapFromClient
|
||||
----------------
|
||||
|
||||
.. code-block:: pascal
|
||||
|
||||
function BitmapFromClient(const xs, ys, xe, ye: Integer): Integer;
|
||||
|
||||
|
||||
SetBitmapName
|
||||
-------------
|
||||
|
||||
.. code-block:: pascal
|
||||
|
||||
procedure SetBitmapName(Bmp : integer; name : string);
|
||||
|
||||
|
||||
FindBitmap
|
||||
----------
|
||||
|
||||
.. code-block:: pascal
|
||||
|
||||
function FindBitmap(bitmap: integer; var x, y: Integer): Boolean;
|
||||
|
||||
|
||||
FindBitmapIn
|
||||
------------
|
||||
|
||||
.. code-block:: pascal
|
||||
|
||||
function FindBitmapIn(bitmap: integer; var x, y: Integer; xs, ys, xe, ye: Integer): Boolean;
|
||||
|
||||
|
||||
FindBitmapToleranceIn
|
||||
---------------------
|
||||
|
||||
.. code-block:: pascal
|
||||
|
||||
function FindBitmapToleranceIn(bitmap: integer; var x, y: Integer; xs, ys, xe, ye: Integer; tolerance: Integer): Boolean;
|
||||
|
||||
|
||||
FindBitmapSpiral
|
||||
----------------
|
||||
|
||||
.. code-block:: pascal
|
||||
|
||||
function FindBitmapSpiral(bitmap: Integer; var x, y: Integer; xs, ys, xe, ye: Integer): Boolean;
|
||||
|
||||
|
||||
FindBitmapsSpiralTolerance
|
||||
--------------------------
|
||||
|
||||
.. code-block:: pascal
|
||||
|
||||
function FindBitmapsSpiralTolerance(bitmap: integer; x, y: Integer; var Points : TPointArray; xs, ys, xe, ye,tolerance: Integer): Boolean;
|
||||
|
||||
|
||||
FindBitmapSpiralTolerance
|
||||
-------------------------
|
||||
|
||||
.. code-block:: pascal
|
||||
|
||||
function FindBitmapSpiralTolerance(bitmap: integer; var x, y: Integer; xs, ys, xe, ye,tolerance : integer): Boolean;
|
||||
|
||||
|
||||
RotateBitmap
|
||||
------------
|
||||
|
||||
.. code-block:: pascal
|
||||
|
||||
function RotateBitmap(bitmap: Integer; angle: Extended): Integer;
|
||||
|
||||
|
||||
DesaturateBitmap
|
||||
----------------
|
||||
|
||||
.. code-block:: pascal
|
||||
|
||||
function DesaturateBitmap(Bitmap : integer) : integer;
|
||||
|
||||
|
||||
InvertBitmap
|
||||
------------
|
||||
|
||||
.. code-block:: pascal
|
||||
|
||||
procedure InvertBitmap(Bitmap : integer);
|
||||
|
||||
|
||||
CopyBitmap
|
||||
----------
|
||||
|
||||
.. code-block:: pascal
|
||||
|
||||
function CopyBitmap(Bitmap: integer) : integer)
|
||||
|
||||
|
||||
GreyScaleBitmap
|
||||
---------------
|
||||
|
||||
.. code-block:: pascal
|
||||
|
||||
function GreyScaleBitmap(bitmap : integer) : integer
|
||||
|
||||
|
||||
BrightnessBitmap
|
||||
----------------
|
||||
|
||||
.. code-block:: pascal
|
||||
|
||||
function BrightnessBitmap(Bitmap,br : integer) : integer;
|
||||
|
||||
|
||||
ContrastBitmap
|
||||
--------------
|
||||
|
||||
.. code-block:: pascal
|
||||
|
||||
function ContrastBitmap(bitmap : integer; co : extended) : integer;
|
||||
|
||||
|
||||
PosterizeBitmap
|
||||
---------------
|
||||
|
||||
.. code-block:: pascal
|
||||
|
||||
function PosterizeBitmap(Bitmap : integer; po : integer) : integer;
|
||||
|
||||
|
||||
CreateMaskFromBitmap
|
||||
--------------------
|
||||
|
||||
.. code-block:: pascal
|
||||
|
||||
function CreateMaskFromBitmap(Bitmap : integer) : TMask;
|
||||
|
||||
|
||||
FindMaskTolerance
|
||||
-----------------
|
||||
|
||||
.. code-block:: pascal
|
||||
|
||||
function FindMaskTolerance(const mask: TMask; var x, y: Integer; xs,ys, xe, ye: Integer; Tolerance, ContourTolerance: Integer): Boolean;
|
||||
|
||||
|
||||
FindBitmapMaskTolerance
|
||||
-----------------------
|
||||
|
||||
.. code-block:: pascal
|
||||
|
||||
function FindBitmapMaskTolerance(mask: Integer; var x, y: Integer; xs, ys, xe, ye: Integer; Tolerance, ContourTolerance: Integer): Boolean;
|
||||
|
||||
|
||||
FindDeformedBitmapToleranceIn
|
||||
-----------------------------
|
||||
|
||||
.. code-block:: pascal
|
||||
|
||||
function FindDeformedBitmapToleranceIn(bitmap: integer; var x,y: Integer; xs, ys, xe, ye: Integer; tolerance: Integer; Range: Integer; AllowPartialAccuracy: Boolean; var accuracy: Extended): Boolean;
|
||||
|
||||
|
||||
DrawTPABitmap
|
||||
-------------
|
||||
|
||||
.. code-block:: pascal
|
||||
|
||||
procedure DrawTPABitmap(bitmap: integer; TPA: TPointArray; Color: integer);
|
||||
|
||||
|
||||
DrawATPABitmap
|
||||
--------------
|
||||
|
||||
.. code-block:: pascal
|
||||
|
||||
procedure DrawATPABitmap(bitmap: integer; ATPA: T2DPointArray);
|
||||
|
||||
|
||||
DrawATPABitmapEx
|
||||
----------------
|
||||
|
||||
.. code-block:: pascal
|
||||
|
||||
procedure DrawATPABitmapEx(bitmap: integer; ATPA: T2DPointArray; Colors: TIntegerArray);
|
||||
|
||||
|
||||
DrawBitmap
|
||||
----------
|
||||
|
||||
.. code-block:: pascal
|
||||
|
||||
procedure DrawBitmap(Bmp: Integer; Dest: TCanvas; x, y: Integer);
|
||||
|
||||
|
||||
RectangleBitmap
|
||||
---------------
|
||||
|
||||
.. code-block:: pascal
|
||||
|
||||
procedure RectangleBitmap(bitmap : integer; const box : TBox; Color : TColor);
|
||||
|
||||
|
||||
FloodFillBitmap
|
||||
---------------
|
||||
|
||||
.. code-block:: pascal
|
||||
|
||||
procedure FloodFillBitmap(bitmap : integer; const StartPoint : TPoint; const SearchCol,ReplaceCol : TColor);
|
||||
|
||||
|
||||
CalculatePixelShift
|
||||
-------------------
|
||||
|
||||
.. code-block:: pascal
|
||||
|
||||
function CalculatePixelShift(Bmp1,Bmp2 : Integer; CompareBox : TBox) : integer;
|
||||
|
||||
|
||||
CalculatePixelTolerance
|
||||
-----------------------
|
||||
|
||||
.. code-block:: pascal
|
||||
|
||||
function CalculatePixelTolerance(Bmp1,Bmp2 : Integer; CompareBox : TBox; CTS : integer) : extended;')
|
||||
|
||||
|
@ -2,7 +2,7 @@
|
||||
.. _scriptref_ocr:
|
||||
|
||||
OCR
|
||||
==============================
|
||||
===
|
||||
Simba has OCR functions (Optical Text Recognition); these are used to *read* text from an image.
|
||||
|
||||
It also has a wide variation of text *finding* functions. Both will be covered in
|
||||
@ -160,7 +160,7 @@ GetTextAtEx
|
||||
|
||||
A general function for reading text.
|
||||
Reads text in the rectangle defined by (*xs*, *ys*), (*xe*, *ye*)
|
||||
with a minimal vertical spacing of *minvspacing*
|
||||
with a minimal vertical spacing of *minvspacing*
|
||||
and a maximal vertical spacing of *maxvspacing*, the text colour should match
|
||||
the colour *color* with the given tolerance *Tolerance*; the length of the text
|
||||
is specified with *len*. Finally, the font to use for the identifying is
|
||||
|
110
Doc/sphinx/scriptref/web.rst
Normal file
110
Doc/sphinx/scriptref/web.rst
Normal file
@ -0,0 +1,110 @@
|
||||
|
||||
.. _scriptref_web:
|
||||
|
||||
Internet Functions
|
||||
==================
|
||||
|
||||
OpenWebPage
|
||||
-----------
|
||||
|
||||
.. code-block:: pascal
|
||||
|
||||
procedure OpenWebPage(const url : string);
|
||||
|
||||
|
||||
GetPage
|
||||
-------
|
||||
|
||||
.. code-block:: pascal
|
||||
|
||||
function GetPage(const url : string): string;
|
||||
|
||||
|
||||
InitializeHTTPClient
|
||||
--------------------
|
||||
|
||||
.. code-block:: pascal
|
||||
|
||||
function InitializeHTTPClient(HandleCookies: Boolean): Integer;
|
||||
|
||||
|
||||
InitializeHTTPClientWrap
|
||||
------------------------
|
||||
|
||||
.. code-block:: pascal
|
||||
|
||||
function InitializeHTTPClientWrap(HandleCookies: Boolean): Integer;
|
||||
|
||||
|
||||
FreeHTTPClient
|
||||
--------------
|
||||
|
||||
.. code-block:: pascal
|
||||
|
||||
procedure FreeHTTPClient(Client: Integer);
|
||||
|
||||
|
||||
GetHTTPPage
|
||||
-----------
|
||||
|
||||
.. code-block:: pascal
|
||||
|
||||
function GetHTTPPage(Client: Integer;const URL: string): string;
|
||||
|
||||
|
||||
SetHTTPUserAgent
|
||||
----------------
|
||||
|
||||
.. code-block:: pascal
|
||||
|
||||
procedure SetHTTPUserAgent(Client: Integer;const Agent: string);
|
||||
|
||||
|
||||
PostHTTPPage
|
||||
------------
|
||||
|
||||
.. code-block:: pascal
|
||||
|
||||
function PostHTTPPage(Client: Integer;const Url,PostData: string): string;
|
||||
|
||||
|
||||
PostHTTPPageEx
|
||||
--------------
|
||||
|
||||
.. code-block:: pascal
|
||||
|
||||
function PostHTTPPageEx(Client: Integer;const Url: string): string;
|
||||
|
||||
|
||||
ClearPostData
|
||||
-------------
|
||||
|
||||
.. code-block:: pascal
|
||||
|
||||
procedure ClearPostData(Client: Integer);
|
||||
|
||||
|
||||
AddPostVariable
|
||||
---------------
|
||||
|
||||
.. code-block:: pascal
|
||||
|
||||
procedure AddPostVariable(Client: Integer;const VarName, VarValue: string);
|
||||
|
||||
|
||||
GetRawHeaders
|
||||
-------------
|
||||
|
||||
.. code-block:: pascal
|
||||
|
||||
function GetRawHeaders(Client: Integer): string;
|
||||
|
||||
|
||||
SetProxy
|
||||
--------
|
||||
|
||||
.. code-block:: pascal
|
||||
|
||||
procedure SetProxy(Client : Integer; pHost, pPort : String);');
|
||||
|
||||
|
134
Doc/sphinx/scriptref/window.rst
Normal file
134
Doc/sphinx/scriptref/window.rst
Normal file
@ -0,0 +1,134 @@
|
||||
|
||||
.. _scriptref_window:
|
||||
|
||||
Target Window Functions
|
||||
=======================
|
||||
|
||||
Freeze
|
||||
------
|
||||
|
||||
.. code-block:: pascal
|
||||
|
||||
function Freeze: boolean;
|
||||
|
||||
|
||||
Unfreeze
|
||||
--------
|
||||
|
||||
.. code-block:: pascal
|
||||
|
||||
function Unfreeze: boolean;
|
||||
|
||||
|
||||
GetClientDimensions
|
||||
-------------------
|
||||
|
||||
.. code-block:: pascal
|
||||
|
||||
procedure GetClientDimensions(var w, h:integer);
|
||||
|
||||
|
||||
SetTargetBitmap
|
||||
---------------
|
||||
|
||||
.. code-block:: pascal
|
||||
|
||||
function SetTargetBitmap(Bitmap : integer): integer;
|
||||
|
||||
|
||||
SetTargetArray
|
||||
--------------
|
||||
|
||||
.. code-block:: pascal
|
||||
|
||||
function SetTargetArray(P: Integer; w, h: integer): integer;
|
||||
|
||||
|
||||
SetEIOSTarget
|
||||
-------------
|
||||
|
||||
.. code-block:: pascal
|
||||
|
||||
function SetEIOSTarget(name: string; initargs: Variant): integer;
|
||||
|
||||
|
||||
SetImageTarget
|
||||
--------------
|
||||
|
||||
.. code-block:: pascal
|
||||
|
||||
procedure SetImageTarget(idx: integer);
|
||||
|
||||
|
||||
SetKeyMouseTarget
|
||||
-----------------
|
||||
|
||||
.. code-block:: pascal
|
||||
|
||||
procedure SetKeyMouseTarget(idx: integer);
|
||||
|
||||
|
||||
GetImageTarget
|
||||
--------------
|
||||
|
||||
.. code-block:: pascal
|
||||
|
||||
function GetImageTarget: integer;
|
||||
|
||||
|
||||
GetKeyMouseTarget
|
||||
-----------------
|
||||
|
||||
.. code-block:: pascal
|
||||
|
||||
function GetKeyMouseTarget: integer;
|
||||
|
||||
|
||||
ExportImageTarget
|
||||
------------------
|
||||
|
||||
.. code-block:: pascal
|
||||
|
||||
function ExportImageTarget : TTarget_Exported;
|
||||
|
||||
|
||||
ExportKeyMouseTarget
|
||||
---------------------
|
||||
|
||||
.. code-block:: pascal
|
||||
|
||||
function ExportKeyMouseTarget : TTarget_Exported;
|
||||
|
||||
|
||||
FreeTarget
|
||||
----------
|
||||
|
||||
.. code-block:: pascal
|
||||
|
||||
procedure FreeTarget(idx: integer);
|
||||
|
||||
|
||||
SetDesktopAsClient
|
||||
------------------
|
||||
|
||||
.. code-block:: pascal
|
||||
|
||||
procedure SetDesktopAsClient;
|
||||
|
||||
|
||||
ActivateClient
|
||||
--------------
|
||||
|
||||
.. code-block:: pascal
|
||||
|
||||
procedure ActivateClient;
|
||||
|
||||
|
||||
IsTargetValid
|
||||
-------------
|
||||
|
||||
.. code-block:: pascal
|
||||
|
||||
function IsTargetValid: boolean;
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user