vec

package
v0.0.0-...-9f40f58 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jan 11, 2022 License: GPL-3.0 Imports: 2 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Dot

func Dot(lhs, rhs Vec3) float64

func Length

func Length(v Vec3) float64

func ToColor

func ToColor(v Vec3) color.RGBA

Types

type Vec3

type Vec3 struct {
	X float64
	Y float64
	Z float64
}

func Add

func Add(lhs, rhs Vec3) Vec3

func Addn

func Addn(vs ...Vec3) Vec3

func Cross

func Cross(lhs, rhs Vec3) Vec3

func FromScalar

func FromScalar(x float64) Vec3

func Mul

func Mul(lhs, rhs Vec3) Vec3

func New

func New(x, y, z float64) Vec3

func Normalize

func Normalize(v Vec3) Vec3

func Pow

func Pow(lhs, rhs Vec3) Vec3

func Scale

func Scale(v Vec3, f float64) Vec3

func Sub

func Sub(lhs, rhs Vec3) Vec3

func Unit

func Unit() Vec3

func Zero

func Zero() Vec3

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL