Versions in this module Expand all Collapse all v0 v0.1.4 Jun 1, 2024 v0.1.3 May 5, 2024 Changes in this version + const AngMotionMax + const DynsSubGps + const DynsTopGps + var BodyBaseType = types.AddType(&types.Type{ ... }) + var BoxType = types.AddType(&types.Type{ ... }) + var CapsuleType = types.AddType(&types.Type{ ... }) + var CylinderType = types.AddType(&types.Type{ ... }) + var GroupType = types.AddType(&types.Type{ ... }) + var NodeBaseType = types.AddType(&types.Type{ ... }) + var SphereType = types.AddType(&types.Type{ ... }) + func AsNode(k tree.Node) (Node, *NodeBase) + type BBox struct + Area float32 + BBox math32.Box3 + BSphere math32.Sphere + VelBBox math32.Box3 + Volume float32 + func (bb *BBox) IntersectsVelBox(oth *BBox) bool + func (bb *BBox) SetBounds(min, max math32.Vector3) + func (bb *BBox) UpdateFromBBox() + func (bb *BBox) VelNilProject() + func (bb *BBox) VelProject(vel math32.Vector3, step float32) + func (bb *BBox) XForm(q math32.Quat, pos math32.Vector3) + type Body interface + AsBodyBase func() *BodyBase + SetDynamic func() *BodyBase + type BodyBase struct + Color string + Rigid Rigid + Vis string + func NewBodyBase(parent tree.Node, name ...string) *BodyBase + func (bb *BodyBase) AsBody() Body + func (bb *BodyBase) AsBodyBase() *BodyBase + func (bb *BodyBase) GroupBBox() + func (bb *BodyBase) SetDynamic() *BodyBase + func (t *BodyBase) New() tree.Node + func (t *BodyBase) NodeType() *types.Type + func (t *BodyBase) SetColor(v string) *BodyBase + func (t *BodyBase) SetInitial(v State) *BodyBase + func (t *BodyBase) SetRel(v State) *BodyBase + func (t *BodyBase) SetRigid(v Rigid) *BodyBase + func (t *BodyBase) SetVis(v string) *BodyBase + type BodyPoint struct + Body Body + Point math32.Vector3 + type Box struct + Size math32.Vector3 + func NewBox(parent tree.Node, name ...string) *Box + func (bx *Box) InitAbs(par *NodeBase) + func (bx *Box) RelToAbs(par *NodeBase) + func (bx *Box) SetBBox() + func (bx *Box) Step(step float32) + func (t *Box) New() tree.Node + func (t *Box) NodeType() *types.Type + func (t *Box) SetColor(v string) *Box + func (t *Box) SetInitial(v State) *Box + func (t *Box) SetRel(v State) *Box + func (t *Box) SetRigid(v Rigid) *Box + func (t *Box) SetSize(v math32.Vector3) *Box + func (t *Box) SetVis(v string) *Box + type Capsule struct + BotRad float32 + Height float32 + TopRad float32 + func NewCapsule(parent tree.Node, name ...string) *Capsule + func (cp *Capsule) InitAbs(par *NodeBase) + func (cp *Capsule) RelToAbs(par *NodeBase) + func (cp *Capsule) SetBBox() + func (cp *Capsule) Step(step float32) + func (t *Capsule) New() tree.Node + func (t *Capsule) NodeType() *types.Type + func (t *Capsule) SetBotRad(v float32) *Capsule + func (t *Capsule) SetColor(v string) *Capsule + func (t *Capsule) SetHeight(v float32) *Capsule + func (t *Capsule) SetInitial(v State) *Capsule + func (t *Capsule) SetRel(v State) *Capsule + func (t *Capsule) SetRigid(v Rigid) *Capsule + func (t *Capsule) SetTopRad(v float32) *Capsule + func (t *Capsule) SetVis(v string) *Capsule + type Contact struct + A Body + B Body + Dist float32 + NormB math32.Vector3 + PtB math32.Vector3 + func (c *Contact) UpdtDist() + type Contacts []*Contact + func BodyVelBBoxIntersects(a, b Node) Contacts + func (cs *Contacts) New(a, b Body) *Contact + type Cylinder struct + BotRad float32 + Height float32 + TopRad float32 + func NewCylinder(parent tree.Node, name ...string) *Cylinder + func (cy *Cylinder) InitAbs(par *NodeBase) + func (cy *Cylinder) RelToAbs(par *NodeBase) + func (cy *Cylinder) SetBBox() + func (cy *Cylinder) Step(step float32) + func (t *Cylinder) New() tree.Node + func (t *Cylinder) NodeType() *types.Type + func (t *Cylinder) SetBotRad(v float32) *Cylinder + func (t *Cylinder) SetColor(v string) *Cylinder + func (t *Cylinder) SetHeight(v float32) *Cylinder + func (t *Cylinder) SetInitial(v State) *Cylinder + func (t *Cylinder) SetRel(v State) *Cylinder + func (t *Cylinder) SetRigid(v Rigid) *Cylinder + func (t *Cylinder) SetTopRad(v float32) *Cylinder + func (t *Cylinder) SetVis(v string) *Cylinder + type Group struct + func NewGroup(parent tree.Node, name ...string) *Group + func (gp *Group) GroupBBox() + func (gp *Group) InitAbs(par *NodeBase) + func (gp *Group) RayBodyIntersections(ray math32.Ray) []*BodyPoint + func (gp *Group) RelToAbs(par *NodeBase) + func (gp *Group) Step(step float32) + func (gp *Group) WorldCollide(dynTop bool) []Contacts + func (gp *Group) WorldDynGroupBBox() + func (gp *Group) WorldInit() + func (gp *Group) WorldRelToAbs() + func (gp *Group) WorldStep(step float32) + func (t *Group) New() tree.Node + func (t *Group) NodeType() *types.Type + func (t *Group) SetInitial(v State) *Group + func (t *Group) SetRel(v State) *Group + type Node interface + AsBody func() Body + AsNodeBase func() *NodeBase + GroupBBox func() + InitAbs func(par *NodeBase) + IsDynamic func() bool + RelToAbs func(par *NodeBase) + Step func(step float32) + type NodeBase struct + Abs State + BBox BBox + Initial State + Rel State + func NewNodeBase(parent tree.Node, name ...string) *NodeBase + func (nb *NodeBase) AsBody() Body + func (nb *NodeBase) AsNodeBase() *NodeBase + func (nb *NodeBase) InitAbsBase(par *NodeBase) + func (nb *NodeBase) IsDynamic() bool + func (nb *NodeBase) RelToAbsBase(par *NodeBase) + func (nb *NodeBase) SetInitAngVel(vel math32.Vector3) *NodeBase + func (nb *NodeBase) SetInitLinVel(vel math32.Vector3) *NodeBase + func (nb *NodeBase) SetInitPos(pos math32.Vector3) *NodeBase + func (nb *NodeBase) SetInitQuat(quat math32.Quat) *NodeBase + func (nb *NodeBase) StepBase(step float32) + func (t *NodeBase) New() tree.Node + func (t *NodeBase) NodeType() *types.Type + func (t *NodeBase) SetInitial(v State) *NodeBase + func (t *NodeBase) SetRel(v State) *NodeBase + type NodeFlags tree.Flags + const Dynamic + const NodeFlagsN + func NodeFlagsValues() []NodeFlags + func (i *NodeFlags) SetFlag(on bool, f ...enums.BitFlag) + func (i *NodeFlags) SetInt64(in int64) + func (i *NodeFlags) SetString(s string) error + func (i *NodeFlags) SetStringOr(s string) error + func (i *NodeFlags) UnmarshalText(text []byte) error + func (i NodeFlags) BitIndexString() string + func (i NodeFlags) Desc() string + func (i NodeFlags) HasFlag(f enums.BitFlag) bool + func (i NodeFlags) Int64() int64 + func (i NodeFlags) MarshalText() ([]byte, error) + func (i NodeFlags) String() string + func (i NodeFlags) Values() []enums.Enum + type Rigid struct + Bounce float32 + Force math32.Vector3 + Friction float32 + InvMass float32 + RotInertia math32.Matrix3 + func (ps *Rigid) Defaults() + type Sphere struct + Radius float32 + func NewSphere(parent tree.Node, name ...string) *Sphere + func (sp *Sphere) InitAbs(par *NodeBase) + func (sp *Sphere) RelToAbs(par *NodeBase) + func (sp *Sphere) SetBBox() + func (sp *Sphere) Step(step float32) + func (t *Sphere) New() tree.Node + func (t *Sphere) NodeType() *types.Type + func (t *Sphere) SetColor(v string) *Sphere + func (t *Sphere) SetInitial(v State) *Sphere + func (t *Sphere) SetRadius(v float32) *Sphere + func (t *Sphere) SetRel(v State) *Sphere + func (t *Sphere) SetRigid(v Rigid) *Sphere + func (t *Sphere) SetVis(v string) *Sphere + type State struct + AngVel math32.Vector3 + LinVel math32.Vector3 + Pos math32.Vector3 + Quat math32.Quat + func (ps *State) Defaults() + func (ps *State) EulerRotation() math32.Vector3 + func (ps *State) EulerRotationRad() math32.Vector3 + func (ps *State) FromRel(rel, par *State) + func (ps *State) Move(delta math32.Vector3) + func (ps *State) MoveOnAxis(x, y, z, dist float32) + func (ps *State) MoveOnAxisAbs(x, y, z, dist float32) + func (ps *State) RotateEuler(x, y, z float32) + func (ps *State) RotateEulerRad(x, y, z, angle float32) + func (ps *State) RotateOnAxis(x, y, z, angle float32) + func (ps *State) RotateOnAxisRad(x, y, z, angle float32) + func (ps *State) SetAxisRotation(x, y, z, angle float32) + func (ps *State) SetAxisRotationRad(x, y, z, angle float32) + func (ps *State) SetEulerRotation(x, y, z float32) + func (ps *State) SetEulerRotationRad(x, y, z float32) + func (ps *State) StepByAngVel(step float32) + func (ps *State) StepByLinVel(step float32)