object

package
v0.0.2 Latest Latest
Warning

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

Go to latest
Published: Jan 27, 2025 License: GPL-3.0 Imports: 8 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Body

type Body struct {
	// contains filtered or unexported fields
}

func (*Body) Add

func (b *Body) Add(s ...*Shape) *Body

func (*Body) Describe

func (b *Body) Describe(desc string) *Body

func (*Body) Object

func (b *Body) Object() *Object

type Context

type Context struct {
	// contains filtered or unexported fields
}

func (*Context) Body

func (c *Context) Body() *Body

func (*Context) Cube

func (c *Context) Cube() *Shape

func (*Context) Cylinder

func (c *Context) Cylinder() *Shape

func (*Context) Debug added in v0.0.2

func (c *Context) Debug() (_ *Shape)

func (*Context) Extrude

func (c *Context) Extrude(profile []tensor.Vec3, path tensor.Vec3) *Shape

func (*Context) Line added in v0.0.2

func (c *Context) Line(v []tensor.Vec3, loop bool) *Object

func (*Context) Models

func (c *Context) Models() []model.Model

func (*Context) Revolve

func (c *Context) Revolve(profile []tensor.Vec3, axis tensor.Vec3) *Shape

func (*Context) Sphere

func (c *Context) Sphere() *Shape

func (*Context) Torus

func (c *Context) Torus(r1, r2 float64) *Shape

type Object

type Object struct {
	// contains filtered or unexported fields
}

func (*Object) Add

func (o *Object) Add()

func (*Object) Apply

func (o *Object) Apply(t model.Transform) *Object

func (*Object) Rotate

func (o *Object) Rotate(angle float64, axis tensor.Vec3) *Object

func (*Object) Scale

func (o *Object) Scale(v tensor.Vec3) *Object

func (*Object) ScaleUniform

func (o *Object) ScaleUniform(v float64) *Object

func (*Object) Spin

func (o *Object) Spin(rate float64, axis tensor.Vec3) *Object

func (*Object) Translate

func (o *Object) Translate(v tensor.Vec3) *Object

func (*Object) Wireframe added in v0.0.2

func (o *Object) Wireframe(cull bool) *Object

type Shape added in v0.0.2

type Shape struct {
	// contains filtered or unexported fields
}

func (*Shape) AddTo added in v0.0.2

func (s *Shape) AddTo(b *Body)

func (*Shape) Apply added in v0.0.2

func (s *Shape) Apply(t shape.Transform) *Shape

func (*Shape) Cleave added in v0.0.2

func (s *Shape) Cleave(point, normal tensor.Vec3) (front, back *Shape)

func (*Shape) ColorRandom added in v0.0.2

func (s *Shape) ColorRandom() *Shape

func (*Shape) ColorUniform added in v0.0.2

func (s *Shape) ColorUniform(c tensor.Vec3) *Shape

func (*Shape) ColorUniformA added in v0.0.2

func (s *Shape) ColorUniformA(c tensor.Vec4) *Shape

func (*Shape) Describe added in v0.0.2

func (s *Shape) Describe(desc string) *Shape

func (*Shape) Object added in v0.0.2

func (s *Shape) Object() *Object

func (*Shape) Rotate added in v0.0.2

func (s *Shape) Rotate(angle float64, axis tensor.Vec3) *Shape

func (*Shape) Scale added in v0.0.2

func (s *Shape) Scale(v tensor.Vec3) *Shape

func (*Shape) ScaleUniform added in v0.0.2

func (s *Shape) ScaleUniform(v float64) *Shape

func (*Shape) Translate added in v0.0.2

func (s *Shape) Translate(v tensor.Vec3) *Shape

Jump to

Keyboard shortcuts

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