Documentation
¶
Index ¶
- Variables
- func CenterFloat3Attribute(m modeling.Mesh, attr string) modeling.Mesh
- func FlatNormals(m modeling.Mesh) modeling.Mesh
- func FlipTriangleWinding(m modeling.Mesh) modeling.Mesh
- func LaplacianSmooth(m modeling.Mesh, attribute string, iterations int, smoothingFactor float64) modeling.Mesh
- func LaplacianSmoothAlongAxis(m modeling.Mesh, attribute string, iterations int, smoothingFactor float64, ...) modeling.Mesh
- func NormalizeAttribute2D(m modeling.Mesh, attribute string) modeling.Mesh
- func NormalizeAttribute3D(m modeling.Mesh, attribute string) modeling.Mesh
- func RemovedUnreferencedVertices(m modeling.Mesh) modeling.Mesh
- func RotateAttribute3D(m modeling.Mesh, attribute string, q modeling.Quaternion) modeling.Mesh
- func ScaleAttribute3D(m modeling.Mesh, attribute string, origin, amount vector3.Float64) modeling.Mesh
- func SliceByPlaneWithAttribute(m modeling.Mesh, plane geometry.Plane, attribute string) (modeling.Mesh, modeling.Mesh)
- func SmoothNormals(m modeling.Mesh) modeling.Mesh
- func SplitOnUniqueMaterials(m modeling.Mesh) []modeling.Mesh
- func TranslateAttribute3D(m modeling.Mesh, attribute string, amount vector3.Float64) modeling.Mesh
- func Unweld(m modeling.Mesh) modeling.Mesh
- func VertexColorSpace(m modeling.Mesh, attribute string, ...) modeling.Mesh
- type CenterAttribute3DTransformer
- type CustomTransformer
- type FlatNormalsTransformer
- type FlipTriangleWindingTransformer
- type LaplacianSmoothTransformer
- type NormalizeAttribute2DTransformer
- type NormalizeAttribute3DTransformer
- type RemovedUnreferencedVerticesTransformer
- type RotateAttribute3DTransformer
- type ScaleAttribute3DTransformer
- type SliceByPlaneTransformer
- type SliceByPlaneTransformerSide
- type SmoothNormalsTransformer
- type TranslateAttribute3DTransformer
- type UnweldTransformer
- type VertexColorSpaceTransformation
- type VertexColorSpaceTransformer
Constants ¶
This section is empty.
Variables ¶
View Source
var ( ErrRequireTriangleTopology = errors.New("mesh is required to have a triangle topology") ErrRequireLineTopology = errors.New("mesh is required to have a line topology") ErrRequirePointTopology = errors.New("mesh is required to have a point topology") ErrRequireDifferentTopology = errors.New("mesh does not have required topology") )
Functions ¶
func LaplacianSmooth ¶
func NormalizeAttribute2D ¶ added in v0.9.0
func NormalizeAttribute3D ¶ added in v0.9.0
func RotateAttribute3D ¶
func ScaleAttribute3D ¶
func TranslateAttribute3D ¶
func Unweld ¶
Unweld duplicates all vertex data such that no two primitive indices share any one vertex
func VertexColorSpace ¶ added in v0.9.0
Types ¶
type CenterAttribute3DTransformer ¶
type CenterAttribute3DTransformer struct {
Attribute string
}
type CustomTransformer ¶
type FlatNormalsTransformer ¶
type FlatNormalsTransformer struct{}
type FlipTriangleWindingTransformer ¶
type FlipTriangleWindingTransformer struct {
Attribute string
}
type NormalizeAttribute2DTransformer ¶ added in v0.9.0
type NormalizeAttribute2DTransformer struct {
Attribute string
}
type NormalizeAttribute3DTransformer ¶ added in v0.9.0
type NormalizeAttribute3DTransformer struct {
Attribute string
}
Finds the vector with the longest length and scales all vectors within the mesh attribute by (1 / longestLength)
type RemovedUnreferencedVerticesTransformer ¶
type RemovedUnreferencedVerticesTransformer struct{}
type RotateAttribute3DTransformer ¶
type RotateAttribute3DTransformer struct {
Attribute string
Amount modeling.Quaternion
}
type ScaleAttribute3DTransformer ¶
type SliceByPlaneTransformer ¶
type SliceByPlaneTransformer struct {
Attribute string
SliceToKeep SliceByPlaneTransformerSide
Plane geometry.Plane
}
type SliceByPlaneTransformerSide ¶
type SliceByPlaneTransformerSide int
const ( AbovePlane SliceByPlaneTransformerSide = iota BelowPlane )
type SmoothNormalsTransformer ¶
type SmoothNormalsTransformer struct{}
type UnweldTransformer ¶
type UnweldTransformer struct{}
type VertexColorSpaceTransformation ¶ added in v0.9.0
type VertexColorSpaceTransformation int
const ( VertexColorSpaceSRGBToLinear VertexColorSpaceTransformation = iota VertexColorSpaceLinearToSRGB )
type VertexColorSpaceTransformer ¶ added in v0.9.0
type VertexColorSpaceTransformer struct {
Attribute string
Transformation VertexColorSpaceTransformation
}
Source Files
¶
- attribute_transformer.go
- center_attribute.go
- custom_transformer.go
- flat_normals.go
- flip_winding.go
- laplacian_smoothing.go
- normalize_attribute_transformer.go
- remove_unreferenced_vertices.go
- rotate_attribute.go
- scale_attribute.go
- slice_by_plane.go
- smooth_normals.go
- split_on_materials.go
- translate_attribute.go
- unweld.go
- util.go
- vertex_color_space.go
Click to show internal directories.
Click to hide internal directories.