PC SOFT

ONLINE HELP
 WINDEVWEBDEV AND WINDEV MOBILE

Home | Sign in | English EN
This content has been translated automatically. Click here to view the French version.
WINDEV
WindowsLinuxUniversal Windows 10 AppJavaReports and QueriesUser code (UMC)
WEBDEV
WindowsLinuxPHPWEBDEV - Browser code
WINDEV Mobile
AndroidAndroid Widget iPhone/iPadIOS WidgetApple WatchMac CatalystUniversal Windows 10 App
Others
Stored procedures
Converts the coordinates of a rectangle in the image to the corresponding coordinates in the Image control. This function is used to match the coordinates of the source image to the coordinates displayed in the Image control.
New in version 28
Android This function is now available for Android applications.
Example
// Chargement de l'image pour l'OCR
ImagePourOCR is Image = dLoadImage(MonImage)
// Affiche une miniature de l'image dans le champ
IMG_Miniature = ImagePourOCR
// Détection des zones de texte
tabZones is array of Polygon = OCRDetectTextArea(ImagePourOCR)
// Dessine les rectangles dans la miniature
dStartDrawing(IMG_Miniature)
FOR EACH rect OF tabZones
// Transforme le polygone en rectangle (ici on considère que le polygone est à angle droit)
recTemp is Rectangle
recTemp.X = rect.Point[1].X
recTemp.Y = rect.Point[1].Y
recTemp.Width = rect.Point[2].X - rect.Point[1].X
recTemp.Height = rect.Point[3].Y - rect.Point[1].Y
   
let rectImage = CoordinateImageToImageControl(IMG_Miniature, recTemp)
dRectangle(rectImage)
END
Syntax
<Result> = CoordinateImageToImageControl(<Image control> , <Coordinates to convert>)
<Result>: Rectangle variable
Rectangle variable that corresponds to the rectangle in relation to the Image control.
<Image control>: Control name
Image control used.
<Coordinates to convert>: Rectangle variable
Name of the Rectangle variable that corresponds to the rectangle in relation image.
Remarks
  • The conversion takes into account the display mode of the image.
  • The function is ignored if the displayed image is repeated.
Component: wd280obj.dll
Minimum version required
  • Version 26
This page is also available for…
Comments
Click [Add] to post a comment