Lazarus
Home
Help
TinyPortal
Search
Login
Register
Lazarus
»
Forum
»
Programming
»
Packages and Libraries
»
function intersect in lazmapviewer
Free Pascal
Website
Downloads
Wiki
Documentation
Bugtracker
Mailing List
Lazarus
Website
Downloads (Laz+FPC)
Packages (OPM)
FAQ
Wiki
Documentation (RTL/FCL/LCL)
Bugtracker
CCR Bugs
GIT
Mailing List
Other languages
Foundation
Website
Useful Wiki Links
Project Roadmap
Getting the Source
Screenshots
How to use the forum
Forum Rules
About donations (wiki)
Bookstore
Computer Math and Games in Pascal
(preview)
Lazarus Handbook
« previous
next »
Print
Pages: [
1
]
Author
Topic: function intersect in lazmapviewer (Read 445 times)
Sukram
Newbie
Posts: 1
function intersect in lazmapviewer
«
on:
February 06, 2026, 07:42:17 pm »
Hello, how do I use the `intersect` function in LazMapViewer? I want to find the point where two lines intersect. Is this function suitable for that, and could I get some example code?
thank you
Logged
wp
Hero Member
Posts: 13651
Re: function intersect in lazmapviewer
«
Reply #1 on:
February 06, 2026, 08:30:39 pm »
You mean this one (in unit mvDrawingEngine)?
Code: Pascal
[Select]
[+]
[-]
// Intersection point between line segments <P1, P2> and <P3, P4>
// Returns:
// 0 - collinear line segments
// 1 - line segments intersect at PX
// 2 - collinear overlapping line segments, PX lies on both
//
function
Intersect
(
P1
,
P2
,
P3
,
P4
:
TPoint
;
out PX
:
TPoint
)
:
Integer
;
Logged
Print
Pages: [
1
]
« previous
next »
Lazarus
»
Forum
»
Programming
»
Packages and Libraries
»
function intersect in lazmapviewer
TinyPortal
© 2005-2018