Documentation
¶
Index ¶
- Constants
- func Cross2(v, w Vec2) float64
- func Determinant2(m Mat2) float64
- func Determinant3(m Mat3) float64
- func Determinant4(m Mat4) float64
- func Diff(vec1, vec2 []float64) []float64
- func Distance3(v, w Vec3) float64
- func Distance4(v, w Vec4) float64
- func DistanceSquared3(v, w Vec3) float64
- func DistanceSquared4(v, w Vec4) float64
- func Dot2(v, w Vec2) float64
- func Dot3(v, w Vec3) float64
- func Dot4(v, w Vec4) float64
- func HDot4(v, w Vec4) float64
- func IsInArray1(value int, list []int) bool
- func IsInArray2(testVector [2]int, groupVectors [][2]int) bool
- func IsInArray4(testVector Vec4, groupVectors []Vec4) bool
- func Norm3(v Vec3) float64
- func Norm4(v Vec4) float64
- func NormSquared3(v Vec3) float64
- func NormSquared4(v Vec4) float64
- func PointInPolygon(point Vec3, polygon []Vec3) bool
- type Line
- type Mat2
- type Mat3
- type Mat4
- type Plane
- type Sphere2
- type Sphere3
- type Vec2
- type Vec3
- type Vec4
- func Cross4(vec1, vec2, vec3 Vec4) Vec4
- func Diff4(v, w Vec4) Vec4
- func EDirectionalTangent(a, b Vec4) Vec4
- func HDirectionalTangent(a, b Vec4) Vec4
- func Midpoint4(v, w Vec4) Vec4
- func NearestPointOnLineToPoint(a, b, c Vec4) Vec4
- func NearestPointOnPlaneToPoint(a, n Vec4) Vec4
- func Reflect(x, n Vec4) Vec4
- func SDirectionalTangent(a, b Vec4) Vec4
- func Scale4(v Vec4, a float64) Vec4
- func Sum4(v, w Vec4) Vec4
- func TransformVertices(baseVertices []Vec4, transformation string, V, E, F, C func(Vec4) Vec4) []Vec4
- func (v *Vec4) Diff(w Vec4)
- func (v *Vec4) Dot(w Vec4) float64
- func (v *Vec4) HDot(w Vec4) float64
- func (v *Vec4) HNormSquared() float64
- func (v *Vec4) HNormalise()
- func (v *Vec4) NormSquared() float64
- func (v *Vec4) Normalise()
- func (v *Vec4) SNormalise()
- func (v *Vec4) Scale(a float64)
- func (v *Vec4) Sum(w Vec4)
- func (v *Vec4) ToSlice() [4]float64
Constants ¶
View Source
const (
IsInArrayEps = 0.00001
)
Variables ¶
This section is empty.
Functions ¶
func Determinant2 ¶
func Determinant3 ¶
func Determinant4 ¶
func DistanceSquared3 ¶ added in v1.2.0
func DistanceSquared4 ¶ added in v1.2.0
func IsInArray1 ¶
func IsInArray2 ¶
func IsInArray4 ¶ added in v1.2.0
func NormSquared3 ¶
func NormSquared4 ¶
func PointInPolygon ¶
Types ¶
type Mat2 ¶ added in v1.2.0
func (*Mat2) Determinant ¶ added in v1.2.0
type Mat3 ¶ added in v1.2.0
type Mat3 struct {
XX float64
XY float64
XZ float64
YX float64
YY float64
YZ float64
ZX float64
ZY float64
ZZ float64
}
XX XY XZ YX YY YZ ZX ZY ZZ
func InitialiseMat3 ¶ added in v1.3.5
func (*Mat3) Determinant ¶ added in v1.2.0
type Mat4 ¶ added in v1.2.0
type Mat4 struct {
WW float64
WX float64
WY float64
WZ float64
XW float64
XX float64
XY float64
XZ float64
YW float64
YX float64
YY float64
YZ float64
ZW float64
ZX float64
ZY float64
ZZ float64
}
func InitialiseFromVectors ¶ added in v1.3.17
func (*Mat4) Determinant ¶ added in v1.2.0
func (*Mat4) MatrixByVector ¶ added in v1.3.17
type Sphere2 ¶ added in v1.2.0
func Circumsphere2 ¶ added in v1.2.0
type Sphere3 ¶ added in v1.2.0
func Circumsphere3 ¶ added in v1.2.0
type Vec2 ¶ added in v1.2.0
func (Vec2) NormSquared ¶ added in v1.2.0
type Vec3 ¶ added in v1.2.0
func (Vec3) NormSquared ¶ added in v1.2.0
type Vec4 ¶ added in v1.2.0
func NearestPointOnLineToPoint ¶ added in v1.3.17
func NearestPointOnPlaneToPoint ¶ added in v1.3.17
func TransformVertices ¶
func (*Vec4) HNormSquared ¶ added in v1.2.0
func (*Vec4) HNormalise ¶ added in v1.2.0
func (v *Vec4) HNormalise()
func (*Vec4) NormSquared ¶ added in v1.2.0
func (*Vec4) SNormalise ¶ added in v1.2.0
func (v *Vec4) SNormalise()
Click to show internal directories.
Click to hide internal directories.