toggle menu
korge-root
5.1.0
common
switch theme
search in API
korge-foundation
/
korlibs.math.geom
/
MLine
MLine
data
class
MLine
(
var
a
:
Point
,
var
b
:
Point
)
Deprecated
Use Line instead
Members
Members & Extensions
Constructors
MLine
Link copied to clipboard
constructor
(
)
constructor
(
p0
:
MPoint
,
p1
:
MPoint
)
constructor
(
x0
:
Double
,
y0
:
Double
,
x1
:
Double
,
y1
:
Double
)
constructor
(
x0
:
Float
,
y0
:
Float
,
x1
:
Float
,
y1
:
Float
)
constructor
(
x0
:
Int
,
y0
:
Int
,
x1
:
Int
,
y1
:
Int
)
constructor
(
a
:
Point
,
b
:
Point
)
Types
Companion
Link copied to clipboard
object
Companion
Properties
a
Link copied to clipboard
var
a
:
Point
angle
Link copied to clipboard
val
angle
:
Angle
b
Link copied to clipboard
var
b
:
Point
delta
Link copied to clipboard
val
delta
:
Point
dx
Link copied to clipboard
val
dx
:
Double
dy
Link copied to clipboard
val
dy
:
Double
length
Link copied to clipboard
val
length
:
Double
length
Squared
Link copied to clipboard
val
lengthSquared
:
Double
max
X
Link copied to clipboard
val
maxX
:
Double
max
Y
Link copied to clipboard
val
maxY
:
Double
min
X
Link copied to clipboard
val
minX
:
Double
min
Y
Link copied to clipboard
val
minY
:
Double
x0
Link copied to clipboard
val
x0
:
Double
x1
Link copied to clipboard
val
x1
:
Double
y0
Link copied to clipboard
val
y0
:
Double
y1
Link copied to clipboard
val
y1
:
Double
Functions
clone
Link copied to clipboard
fun
clone
(
)
:
MLine
contains
Bounds
XY
Link copied to clipboard
fun
containsBoundsXY
(
x
:
Double
,
y
:
Double
)
:
Boolean
contains
X
Link copied to clipboard
fun
containsX
(
x
:
Double
)
:
Boolean
contains
Y
Link copied to clipboard
fun
containsY
(
y
:
Double
)
:
Boolean
direction
Vector
Link copied to clipboard
fun
directionVector
(
out
:
MPoint
=
MPoint()
)
:
MPoint
flipped
Link copied to clipboard
fun
flipped
(
)
:
MLine
get
Intersection
Point
Link copied to clipboard
fun
getIntersectionPoint
(
line
:
MLine
)
:
Point
?
get
Line
Intersection
Point
Link copied to clipboard
fun
getLineIntersectionPoint
(
line
:
MLine
)
:
Point
?
get
Minimum
Distance
Link copied to clipboard
fun
getMinimumDistance
(
p
:
Point
)
:
Double
get
Segment
Intersection
Point
Link copied to clipboard
fun
getSegmentIntersectionPoint
(
line
:
MLine
)
:
Point
?
intersects
Link copied to clipboard
fun
intersects
(
line
:
MLine
)
:
Boolean
intersects
Line
Link copied to clipboard
fun
intersectsLine
(
line
:
MLine
)
:
Boolean
intersects
Segment
Link copied to clipboard
fun
intersectsSegment
(
line
:
MLine
)
:
Boolean
projected
Point
Link copied to clipboard
fun
MLine
.
projectedPoint
(
point
:
Point
)
:
Point
round
Link copied to clipboard
fun
round
(
)
:
MLine
scale
Points
Link copied to clipboard
fun
scalePoints
(
scale
:
Double
)
:
MLine
set
To
Link copied to clipboard
fun
setTo
(
a
:
MPoint
,
b
:
MPoint
)
:
MLine
fun
setTo
(
a
:
Point
,
b
:
Point
)
:
MLine
fun
setTo
(
x0
:
Double
,
y0
:
Double
,
x1
:
Double
,
y1
:
Double
)
:
MLine
set
To
Polar
Link copied to clipboard
fun
setToPolar
(
x
:
Double
,
y
:
Double
,
angle
:
Angle
,
length
:
Double
=
1.0
)
:
MLine
to
Bezier
Link copied to clipboard
fun
MLine
.
toBezier
(
)
:
Bezier
to
String
Link copied to clipboard
open
override
fun
toString
(
)
:
String