Einzelnen Beitrag anzeigen

Benutzerbild von DeddyH
DeddyH

Registriert seit: 17. Sep 2006
Ort: Barchfeld
27.542 Beiträge
 
Delphi 11 Alexandria
 
#2

AW: Runtime Error bei PtInRegion

  Alt 23. Dez 2012, 13:16
Zerstörst Du die Regions denn auch wieder, wenn Du sie nicht mehr brauchst? Außerdem sollte man evtl. abprüfen, ob sie überhaupt erzeugt wurden.

[edit]
Zitat:
Return value

If the function succeeds, the return value is the handle to the region.

If the function fails, the return value is NULL.
Remarks

When you no longer need the HRGN object, call the DeleteObject function to delete it.

Region coordinates are represented as 27-bit signed integers.

Regions created by the Create<shape>Rgn methods (such as CreateRectRgn and CreatePolygonRgn) only include the interior of the shape; the shape's outline is excluded from the region. This means that any point on a line between two sequential vertices is not included in the region. If you were to call PtInRegion for such a point, it would return zero as the result.
[/edit]
Detlef
"Ich habe Angst vor dem Tag, an dem die Technologie unsere menschlichen Interaktionen übertrumpft. Die Welt wird eine Generation von Idioten bekommen." (Albert Einstein)
Dieser Tag ist längst gekommen
  Mit Zitat antworten Zitat