transform

package
v0.0.0-...-ddc071b Latest Latest
Warning

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

Go to latest
Published: Feb 26, 2023 License: GPL-3.0 Imports: 3 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Apply

func Apply(a matrix.Mat, b matrix.Mat) matrix.Mat

Types

type Transform

type Transform struct {
	Matrix matrix.Mat
}

Holds Transform Matrix

func (*Transform) EulerRotate

func (T *Transform) EulerRotate(yaw float32, pitch float32, roll float32)

EulerRotate compactifies the intended yaw / pitch / roll values into a rotation matrix form

func (*Transform) Rotate

func (T *Transform) Rotate(axis vector.Vec, angle float32) matrix.Mat

Rotate applies matrix rotation of the angle theta which should be in radians, The rotation axis is given by the Vector axis (l, m, n)

func (*Transform) Translate

func (T *Transform) Translate(vec vector.Vec) matrix.Mat

Augments Transform Matrix with Translation

func (*Transform) Translate3VF

func (T *Transform) Translate3VF(vec vector.Vec) vector.Vec

Applies tranform matrix to a vector

Jump to

Keyboard shortcuts

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