Documentation ¶
Index ¶
- func RectsIntersect(min0, max0, min1, max1 *Vec2f) bool
- func VecCross(v0, v1 *Vec2f) float64
- func VecDot(v0, v1 *Vec2f) float64
- type Vec2f
- func (vec *Vec2f) Add(other *Vec2f) *Vec2f
- func (vec *Vec2f) AddScalar(scalar float64) *Vec2f
- func (vec *Vec2f) Ceil() *Vec2f
- func (vec *Vec2f) Clone() *Vec2f
- func (vec *Vec2f) Equals(other *Vec2f) bool
- func (vec *Vec2f) Floor() *Vec2f
- func (vec *Vec2f) Length() float64
- func (vec *Vec2f) Lerp(other *Vec2f, t float64) *Vec2f
- func (vec *Vec2f) Normalize() *Vec2f
- func (vec *Vec2f) Scale(s float64) *Vec2f
- func (vec *Vec2f) Sub(other *Vec2f) *Vec2f
- func (vec *Vec2f) SubScalar(scalar float64) *Vec2f
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func RectsIntersect ¶
Types ¶
type Vec2f ¶
type Vec2f struct {
X, Y float64
}
func RandomDirection ¶
func RandomDirection() *Vec2f
func VecFromAngle ¶
Click to show internal directories.
Click to hide internal directories.