extrude

package
v0.17.0 Latest Latest
Warning

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

Go to latest
Published: Nov 17, 2024 License: MIT Imports: 9 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func CircleWithConstantThickness

func CircleWithConstantThickness(sides int, thickness float64, path []vector3.Float64) modeling.Mesh

func CircleWithThickness

func CircleWithThickness(sides int, thickness []float64, path []vector3.Float64) modeling.Mesh

func ClosedCircleWithConstantThickness

func ClosedCircleWithConstantThickness(sides int, thickness float64, path []vector3.Float64) modeling.Mesh

func ClosedCircleWithThickness

func ClosedCircleWithThickness(sides int, thickness []float64, path []vector3.Float64) modeling.Mesh

func ClosedShape

func ClosedShape(shape []vector2.Float64, path []vector3.Float64) modeling.Mesh

func DirectionsOfPoints added in v0.10.0

func DirectionsOfPoints(points []vector3.Float64) []vector3.Float64

func GetPlaneOuterPoints

func GetPlaneOuterPoints(center, normal, perpendicular vector3.Float64, radius float64, sides int) ([]vector3.Float64, []vector3.Float64)

func Line

func Line(linePoints []LinePoint) modeling.Mesh

func PathPoints added in v0.10.0

func PathPoints(stencil []vector2.Float64, path []vector3.Float64) [][]vector3.Float64

func PathPoints2 added in v0.10.0

func PathPoints2(stencil []vector2.Float64, path []vector3.Float64) [][]vector3.Float64

func Polygon

func Polygon(sides int, points []ExtrusionPoint) modeling.Mesh

func ProjectFace

func ProjectFace(center, normal, perpendicular vector3.Float64, shape []vector2.Float64) ([]vector3.Float64, []vector3.Float64)

TODO

		Pretty sure normal calculation is wrong. Need to determine what is and
     isn't a convex / concave point

func Shape

func Shape(shape []vector2.Float64, path []vector3.Float64) modeling.Mesh

Types

type ExtrusionPoint

type ExtrusionPoint struct {
	Point     vector3.Float64
	Thickness float64
	UV        *ExtrusionPointUV
	Direction *ExtrusionPointDirection
}

type ExtrusionPointDirection added in v0.9.0

type ExtrusionPointDirection struct {
	Direction vector3.Float64
}

type ExtrusionPointUV added in v0.9.0

type ExtrusionPointUV struct {
	Point     vector2.Float64
	Thickness float64
}

type LinePoint

type LinePoint struct {
	Point   vector3.Float64
	Up      vector3.Float64
	Width   float64
	Height  float64
	Uv      vector2.Float64
	UvWidth float64
}

type PolygonNode added in v0.17.0

type PolygonNodeData added in v0.17.0

type PolygonNodeData struct {
	Closed         nodes.NodeOutput[bool]
	Sides          nodes.NodeOutput[int]
	ThicknessScale nodes.NodeOutput[float64]
	Thickness      nodes.NodeOutput[[]float64]
	Path           nodes.NodeOutput[[]vector3.Float64]
}

func (PolygonNodeData) Process added in v0.17.0

func (pnd PolygonNodeData) Process() (modeling.Mesh, error)

type ScrewNode added in v0.17.0

type ScrewNodeData added in v0.17.0

type ScrewNodeData struct {
	Line        nodes.NodeOutput[[]vector3.Float64]
	Segments    nodes.NodeOutput[int]
	Revolutions nodes.NodeOutput[float64]
	Distance    nodes.NodeOutput[float64]
	UVs         nodes.NodeOutput[primitives.StripUVs]
}

func (ScrewNodeData) Process added in v0.17.0

func (snd ScrewNodeData) Process() (modeling.Mesh, error)

Jump to

Keyboard shortcuts

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