# Point2d

class Point2d : Tuple2d

A point in 2D space represented by x and y coordinate asn doubles

## Constructors

Point2d
Link copied to clipboard
constructor()
constructor(x: Double, y: Double)
constructor(location: Point2d)

## Properties

x
Link copied to clipboard
var x: Double
y
Link copied to clipboard
var y: Double

## Functions

add
Link copied to clipboard
fun add(otherTuple: Tuple2d)
distance
Link copied to clipboard
fun distance(p: Point2d): Double
distanceSquared
Link copied to clipboard
fun distanceSquared(p: Point2d): Double
scale
Link copied to clipboard
fun scale(scale: Double)
set
Link copied to clipboard
fun set(value: Tuple2d)
operator fun set(x: Double, y: Double)
sub
Link copied to clipboard
fun sub(otherTuple: Tuple2d)
fun sub(t1: Tuple2d, t2: Tuple2d)
toString
Link copied to clipboard
open override fun toString(): String