Versions in this module Expand all Collapse all v0 v0.0.1 Jun 24, 2021 Changes in this version + type AABB struct + Max math.Vector + Min math.Vector + func NewAABB(vs ...math.Vector) AABB + func (aabb *AABB) Add(aabb2 AABB) + func (aabb *AABB) Intersect(aabb2 AABB) bool + func (aabb AABB) Eq(aabb2 AABB) bool + type Face interface + AABB func() AABB + Normal func() math.Vector + Triangles func(func(t *Triangle) bool) + Vertices func(func(v *Vertex) bool) + type Halfedge struct + func (he *Halfedge) Cotan() float64 + func (he *Halfedge) DihedralAngle() float64 + func (he *Halfedge) Vec() math.Vector + type Polygon struct + func NewPolygon(vs ...*Vertex) (*Polygon, error) + func (p *Polygon) AABB() AABB + func (p *Polygon) Normal() math.Vector + func (p *Polygon) Triangles(iter func(t *Triangle) bool) + func (p *Polygon) Vertices(iter func(v *Vertex) bool) + type Quad struct + func NewQuad(v1, v2, v3, v4 *Vertex) *Quad + func (q *Quad) AABB() AABB + func (q *Quad) Normal() math.Vector + func (q *Quad) Triangles(f func(*Triangle) bool) + func (q *Quad) Vertices(f func(v *Vertex) bool) + type Triangle struct + V1 Vertex + V2 Vertex + V3 Vertex + func NewTriangle(v1, v2, v3 *Vertex) *Triangle + func (t *Triangle) AABB() AABB + func (t *Triangle) Normal() math.Vector + func (t *Triangle) Triangles(f func(*Triangle) bool) + func (t *Triangle) Vertices(f func(v *Vertex) bool) + type Vertex struct + Col color.RGBA + Nor math.Vector + Pos math.Vector + UV math.Vector + func NewRandomVertex() *Vertex + func (v *Vertex) AABB() AABB