Versions in this module Expand all Collapse all v1 v1.0.1 Aug 3, 2023 Changes in this version type Geometry + func (g *Geometry) GetOldVerts() []int type Matrix + func GetGlobalMatrix(o Obj) Matrix + func (mat *Matrix) ToArray() [16]float64 type Mesh + func (m *Mesh) GetGeometricMatrix() Matrix type Skin + Clusters []*Cluster type Texture + func (t *Texture) GetFileName() string + func (t *Texture) GetRelativeFileName() *DataView v0 v0.1.0 Jul 24, 2018 Changes in this version + const BoneRotate + const BoneScale + const BoneTranslate + const MaxUvs + var CoordAxis = CoordSystemRight + var CoordAxisSign = 1 + var CustomFrameRate float32 = -1.0 + var FrontAxis = FrontVectorParityOdd + var FrontAxisSign = 1 + var OriginalUnitScaleFactor float32 = 1 + var OriginalUpAxis int + var OriginalUpAxisSign = 1 + var TimeMode = FrameRateDefault + var TimeSpanStart uint64 + var TimeSpanStop uint64 + var UnitScaleFactor float32 = 1 + var UpAxis = UpVectorX + var UpAxisSign = 1 + func GetFramerateFromTimeMode(f FrameRate, custom float32) float32 + func Vec2FromString(str, end string, val *floatgeom.Point2) string + func Vec3FromString(str, end string, val *floatgeom.Point3) string + func Vec4FromString(str, end string, val *floatgeom.Point4) string + type AnimationCurve struct + AttrData []float32 + AttrFlags []int64 + AttrRefCount []int64 + Times []time.Duration + Values []float32 + func NewAnimationCurve(scene *Scene, element *Element) *AnimationCurve + func (ac *AnimationCurve) String() string + func (ac *AnimationCurve) Type() Type + type AnimationCurveNode struct + Bone Obj + BoneLinkProp string + Curves [3]Curve + func NewAnimationCurveNode(s *Scene, e *Element) *AnimationCurveNode + func (acn *AnimationCurveNode) String() string + func (acn *AnimationCurveNode) Type() Type + type AnimationLayer struct + CurveNodes []*AnimationCurveNode + func NewAnimationLayer(scene *Scene, element *Element) *AnimationLayer + func (as *AnimationLayer) String() string + func (as *AnimationLayer) Type() Type + type AnimationStack struct + Layers []*AnimationLayer + func NewAnimationStack(scene *Scene, element *Element) *AnimationStack + func (as *AnimationStack) String() string + func (as *AnimationStack) Type() Type + type Cluster struct + Indices []int + Link Obj + Skin *Skin + Transform Matrix + TransformLink Matrix + Weights []float64 + func NewCluster(scene *Scene, element *Element) *Cluster + func (c *Cluster) String() string + func (c *Cluster) Type() Type + type Color struct + B float32 + G float32 + R float32 + func (c *Color) String() string + type Connection struct + func (c *Connection) String() string + type ConnectionType int + const ObjectConn + const PropConn + func (ct ConnectionType) String() string + type CoordSystem int + const CoordSystemLeft + const CoordSystemRight + type CountReader struct + ReadSoFar int + func NewCountReader(r io.Reader) *CountReader + func (c *CountReader) Read(p []byte) (n int, err error) + type Cursor struct + func (c *Cursor) ReadSoFar() int + type Curve struct + Curve *AnimationCurve + func (c *Curve) String() string + type CurveMode int + const ROTATION + const SCALE + const TRANSLATION + type DataView struct + func BufferDataView(buff *bytes.Buffer) *DataView + func NewDataView(s string) *DataView + func (dv *DataView) String() string + type Element struct + Children []*Element + ID *DataView + Properties []*Property + func (e *Element) String() string + type FrameRate int + const FrameRate100 + const FrameRate1000 + const FrameRate120 + const FrameRate30 + const FrameRate30Drop + const FrameRate48 + const FrameRate50 + const FrameRate60 + const FrameRateCinema + const FrameRateCinemaND + const FrameRateCustom + const FrameRateDefault + const FrameRateNTSCDropFrame + const FrameRateNTSCFullFrame + const FrameRatePAL + type FrontVector int + const FrontVectorParityEven + const FrontVectorParityOdd + type Geometry struct + Colors []floatgeom.Point4 + Faces [][]int + Materials []int + Normals []floatgeom.Point3 + Skin *Skin + Tangents []floatgeom.Point3 + UVs [MaxUvs][]floatgeom.Point2 + Vertices []floatgeom.Point3 + func NewGeometry(scene *Scene, element *Element) *Geometry + func (g *Geometry) String() string + func (g *Geometry) Type() Type + type Header struct + Magic [21]uint8 + Reserved [2]uint8 + Version uint32 + func (h Header) String() string + type Material struct + AmbientColor Color + DiffuseColor Color + DiffuseFactor float64 + EmissiveColor Color + EmissiveFactor float64 + ReflectionColor Color + ReflectionFactor float64 + Shininess float64 + ShininessExponent float64 + SpecularColor Color + SpecularFactor float64 + Textures [TextureCOUNT]*Texture + TransparentColor Color + func NewMaterial(scene *Scene, element *Element) *Material + func (m *Material) String() string + func (m *Material) Type() Type + type Matrix struct + func (m1 Matrix) Mul(m2 Matrix) Matrix + type Mesh struct + Geometry *Geometry + Materials []*Material + func NewMesh(scene *Scene, element *Element) *Mesh + func (m *Mesh) Animations() []*AnimationStack + func (m *Mesh) String() string + func (m *Mesh) Type() Type + type NeedsPostProcessing interface + type Node struct + func NewNode(scene *Scene, element *Element, typ Type) *Node + func (n *Node) String() string + func (n *Node) Type() Type + type NodeAttribute struct + Attribute *DataView + func NewNodeAttribute(scene *Scene, element *Element) *NodeAttribute + func (na *NodeAttribute) String() string + func (na *NodeAttribute) Type() Type + type Obj interface + Element func() *Element + ID func() uint64 + IsNode func() bool + Name func() string + NodeAttribute func() Obj + Scene func() *Scene + SetID func(uint64) + SetNodeAttribute func(na Obj) + String func() string + Type func() Type + type Object struct + func NewObject(scene *Scene, e *Element) *Object + func (o *Object) Element() *Element + func (o *Object) ID() uint64 + func (o *Object) IsNode() bool + func (o *Object) Name() string + func (o *Object) NodeAttribute() Obj + func (o *Object) Scene() *Scene + func (o *Object) SetID(i uint64) + func (o *Object) SetNodeAttribute(na Obj) + func (o *Object) String() string + type Property struct + Count int + Encoding uint32 + Type PropertyType + func (p *Property) String() string + type PropertyType rune + const ArrayBOOL + const ArrayBYTE + const ArrayDOUBLE + const ArrayFLOAT + const ArrayINT + const ArrayLONG + const BOOL + const DOUBLE + const FLOAT + const INT16 + const INTEGER + const LONG + const RAWSTRING + const STRING + func (pt PropertyType) IsArray() bool + func (pt PropertyType) Size() int + type Quat struct + X float64 + Y float64 + Z float64 + type RotationOrder int + const EulerXYZ + const EulerXZY + const EulerYXZ + const EulerYZX + const EulerZXY + const EulerZYX + const SphericXYZ + type Scene struct + AnimationStacks []*AnimationStack + Connections []Connection + FrameRate float32 + Meshes []*Mesh + ObjectMap map[uint64]Obj + RootElement *Element + RootNode *Node + TakeInfos []TakeInfo + func Load(r io.Reader) (*Scene, error) + func (s *Scene) Geometries() []*Geometry + func (s *Scene) String() string + type Settings struct + CoordAxis CoordSystem + CoordAxisSign int + CustomFrameRate float32 + FrontAxis FrontVector + FrontAxisSign int + OriginalUnitScaleFactor float32 + OriginalUpAxis int + OriginalUpAxisSign int + TimeMode FrameRate + TimeSpanStart uint64 + TimeSpanStop uint64 + UnitScaleFactor float32 + UpAxis UpVector + UpAxisSign int + type Skin struct + func NewSkin(scene *Scene, element *Element) *Skin + func (s *Skin) String() string + func (s *Skin) Type() Type + type TakeInfo struct + func (t *TakeInfo) String() string + type Texture struct + func NewTexture(scene *Scene, element *Element) *Texture + func (t *Texture) String() string + func (t *Texture) Type() Type + type TextureType int + const DIFFUSE + const NORMAL + const TextureCOUNT + type Type int + const ANIMATION_CURVE + const ANIMATION_CURVE_NODE + const ANIMATION_LAYER + const ANIMATION_STACK + const CLUSTER + const GEOMETRY + const LIMB_NODE + const MATERIAL + const MESH + const NODE_ATTRIBUTE + const NOTYPE + const NULL_NODE + const ROOT + const SKIN + const TEXTURE + func (t Type) String() string + type UpVector int + const UpVectorX + const UpVectorY + const UpVectorZ + type Vertex struct + type VertexDataMapping int + const ByPolygon + const ByPolygonVertex + const ByVertex