geom

package
v0.0.1 Latest Latest
Warning

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

Go to latest
Published: Jun 15, 2021 License: GPL-3.0 Imports: 3 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Face

type Face interface {
	Set(int, Vec)
	Vec() []Vec
}

func Circle

func Circle(resolution int, radius float32, center, normal Vec) Face

func Flip

func Flip(f Face) Face

func NewFace

func NewFace(n int) Face

func Transform

func Transform(f Face, x Mat) Face

type FaceShape

type FaceShape []Face

func Extrude

func Extrude(profile Face, path Vec) FaceShape

func Sphere

func Sphere(radius float32, center Vec) FaceShape

func (FaceShape) Face

func (v FaceShape) Face() []Face

type Hex

type Hex [5]Vec

func (*Hex) Set

func (v *Hex) Set(i int, u Vec)

func (*Hex) Vec

func (v *Hex) Vec() []Vec

type Mat

type Mat = mgl32.Mat4

type Pent

type Pent [5]Vec

func (*Pent) Set

func (v *Pent) Set(i int, u Vec)

func (*Pent) Vec

func (v *Pent) Vec() []Vec

type Poly

type Poly []Vec

func (Poly) Set

func (v Poly) Set(i int, u Vec)

func (Poly) Vec

func (v Poly) Vec() []Vec

type Quad

type Quad [4]Vec

func (*Quad) Set

func (v *Quad) Set(i int, u Vec)

func (*Quad) Vec

func (v *Quad) Vec() []Vec

type QuadShape

type QuadShape []Quad

func Cube

func Cube(x0, y0, z0, x1, y1, z1 float32) QuadShape

func Revolve

func Revolve(profile Face, axis Vec, resolution int) QuadShape

func Sweep

func Sweep(from, to Face) QuadShape

func Torus

func Torus(r1, r2 float32) QuadShape

func (QuadShape) Face

func (v QuadShape) Face() []Face

type Shape

type Shape interface {
	Face() []Face
}

func Cylinder

func Cylinder(center, along Vec) Shape

type Tri

type Tri [3]Vec

func (*Tri) Set

func (v *Tri) Set(i int, u Vec)

func (*Tri) Vec

func (v *Tri) Vec() []Vec

type Vec

type Vec = mgl32.Vec3

func Normal

func Normal(f Face) Vec

Jump to

Keyboard shortcuts

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