exception Vector2fs_exception of string
Raised when an error occurs (usually a division by zero)
This module defines the vector2fs type and various operations on it.
exception Vector2fs_exception of string
type t = {r : float; t : float}
r : float
|
Signed radius |
t : float
|
Theta angle. An angle of 0 corresponds to a vector pointing towards positive X. |
val zero : t
val unit_x : t
val unit_y : t
val prop : float -> t -> t
val div : float -> t -> t
val to_cartesian : t -> Vector2f.t
val from_cartesian : Vector2f.t -> t
val norm : t -> float
val normalize : t -> t
val print : t -> string