openrndr
Toggle table of contents
0.4.5-dev.17.uncommitted+81afe70
common
Platform filter
common
Switch theme
Search in API
openrndr
openrndr-kartifex
/
org.openrndr.kartifex
/
Vec2
Vec2
@
JvmRecord
data
class
Vec2
(
val
x
:
Double
,
val
y
:
Double
)
:
Vec
<
Vec2
>
(
source
)
Members
Constructors
Vec2
Link copied to clipboard
constructor
(
x
:
Double
,
y
:
Double
)
Types
Companion
Link copied to clipboard
object
Companion
Properties
x
Link copied to clipboard
val
x
:
Double
y
Link copied to clipboard
val
y
:
Double
Functions
abs
Link copied to clipboard
open
fun
abs
(
)
:
Vec2
add
Link copied to clipboard
open
override
fun
add
(
n
:
Double
)
:
Vec2
open
override
fun
add
(
v
:
Vec2
)
:
Vec2
fun
add
(
x
:
Double
,
y
:
Double
)
:
Vec2
any
Link copied to clipboard
open
override
fun
any
(
f
:
DoublePredicate
)
:
Boolean
array
Link copied to clipboard
open
override
fun
array
(
)
:
DoubleArray
clamp
Link copied to clipboard
open
fun
clamp
(
min
:
Double
,
max
:
Double
)
:
Vec2
open
fun
clamp
(
min
:
Vec2
,
max
:
Vec2
)
:
Vec2
compare
To
Link copied to clipboard
open
operator override
fun
compareTo
(
other
:
Vec2
)
:
Int
dim
Link copied to clipboard
open
override
fun
dim
(
)
:
Int
div
Link copied to clipboard
open
operator
fun
div
(
k
:
Double
)
:
Vec2
open
operator override
fun
div
(
v
:
Vec2
)
:
Vec2
equals
Link copied to clipboard
open
operator override
fun
equals
(
other
:
Any
?
)
:
Boolean
every
Link copied to clipboard
open
override
fun
every
(
f
:
DoublePredicate
)
:
Boolean
hash
Code
Link copied to clipboard
open
override
fun
hashCode
(
)
:
Int
length
Link copied to clipboard
open
fun
length
(
)
:
Double
length
Squared
Link copied to clipboard
open
fun
lengthSquared
(
)
:
Double
map
Link copied to clipboard
open
override
fun
map
(
f
:
DoubleUnaryOperator
)
:
Vec2
mul
Link copied to clipboard
open
override
fun
mul
(
k
:
Double
)
:
Vec2
open
override
fun
mul
(
v
:
Vec2
)
:
Vec2
negate
Link copied to clipboard
open
override
fun
negate
(
)
:
Vec2
norm
Link copied to clipboard
open
fun
norm
(
)
:
Vec2
nth
Link copied to clipboard
open
override
fun
nth
(
idx
:
Int
)
:
Double
polar2
Link copied to clipboard
fun
polar2
(
)
:
Polar2
pseudo
Norm
Link copied to clipboard
open
fun
pseudoNorm
(
)
:
Vec2
reduce
Link copied to clipboard
open
override
fun
reduce
(
f
:
DoubleBinaryOperator
)
:
Double
open
override
fun
reduce
(
f
:
DoubleBinaryOperator
,
init
:
Double
)
:
Double
rotate
Link copied to clipboard
fun
rotate
(
radians
:
Double
)
:
Vec2
sub
Link copied to clipboard
open
override
fun
sub
(
n
:
Double
)
:
Vec2
open
override
fun
sub
(
v
:
Vec2
)
:
Vec2
fun
sub
(
x
:
Double
,
y
:
Double
)
:
Vec2
swap
Link copied to clipboard
fun
swap
(
)
:
Vec2
to
String
Link copied to clipboard
open
override
fun
toString
(
)
:
String
transform
Link copied to clipboard
fun
transform
(
m
:
Matrix3
)
:
Vec2
vec3
Link copied to clipboard
fun
vec3
(
z
:
Double
)
:
Vec3
vec4
Link copied to clipboard
fun
vec4
(
v
:
Vec2
)
:
Vec4
fun
vec4
(
z
:
Double
,
w
:
Double
)
:
Vec4
zip
Link copied to clipboard
open
override
fun
zip
(
v
:
Vec2
,
f
:
DoubleBinaryOperator
)
:
Vec2