Documentation
¶
Index ¶
- Constants
- Variables
- func AddChild(parent INode, child INode, childID string)
- func UnmarshalChildren(value *yaml.Node, node INode) error
- type Event
- type IEvent
- type IEventArgs
- type INode
- type ISubNode
- type Node
- func (node *Node) AddChild(child INode, id string)
- func (node *Node) AddEvent(event IEvent, id string)
- func (node *Node) GetBase() INode
- func (node *Node) GetChildren() map[string]INode
- func (node *Node) GetEventByID(id string) IEvent
- func (node *Node) GetGlobalPosition() GeometryMath.Vector3
- func (node *Node) GetGlobalRotation() []GeometryMath.EulerAngles
- func (node *Node) GetGlobalTransformation() GeometryMath.Matrix4x4
- func (node *Node) GetGrandChildById(id string) INode
- func (node *Node) GetID() string
- func (node *Node) GetLocalPosition() GeometryMath.Vector3
- func (node *Node) GetLocalRotation() []GeometryMath.EulerAngles
- func (node *Node) GetLocalTransformation() GeometryMath.Matrix4x4
- func (node *Node) GetParent() INode
- func (node *Node) GetScene() *Scene
- func (node *Node) SetID(id string)
- func (node *Node) SetLocalTransformation(matrix GeometryMath.Matrix4x4)
- func (node *Node) SetParent(parent INode, childID string)
- func (node *Node) SetScene(scene *Scene)
- func (node *Node) Start() error
- func (node *Node) Tick(timeDelta float32) error
- func (node *Node) UnmarshalYAML(value *yaml.Node) error
- type Scene
Constants ¶
View Source
const (
NodeFactoryName = "Scene.Node"
)
Variables ¶
View Source
var (
NodeFactory = nodeFactory{}
)
Functions ¶
Types ¶
type Event ¶
type Event struct {
Listeners []chan IEventArgs
}
func (*Event) DeregisterListener ¶
func (event *Event) DeregisterListener(listener chan IEventArgs)
func (*Event) NotifyListeners ¶
func (event *Event) NotifyListeners(eventArgs IEventArgs)
func (*Event) RegisterListener ¶
func (event *Event) RegisterListener(listener chan IEventArgs)
type IEvent ¶
type IEvent interface {
RegisterListener(listener chan IEventArgs)
DeregisterListener(listener chan IEventArgs)
NotifyListeners(eventArgs IEventArgs)
}
type IEventArgs ¶
type IEventArgs interface {
}
type INode ¶
type INode interface {
AddChild(child INode, id string)
GetChildren() map[string]INode
GetGrandChildById(id string) INode
SetID(id string)
GetID() string
GetParent() INode
SetParent(parent INode, childID string)
GetScene() *Scene
SetScene(*Scene)
GetLocalTransformation() GeometryMath.Matrix4x4
SetLocalTransformation(GeometryMath.Matrix4x4)
GetLocalRotation() []GeometryMath.EulerAngles
GetLocalPosition() GeometryMath.Vector3
GetGlobalTransformation() GeometryMath.Matrix4x4
GetGlobalRotation() []GeometryMath.EulerAngles
GetGlobalPosition() GeometryMath.Vector3
Tick(timeDelta float32) error
GetBase() INode
Start() error
AddEvent(event IEvent, id string)
GetEventByID(id string) IEvent
}
type Node ¶
type Node struct {
Transformation GeometryMath.Matrix4x4
// contains filtered or unexported fields
}
func (*Node) GetChildren ¶
func (*Node) GetEventByID ¶
func (*Node) GetGlobalPosition ¶
func (node *Node) GetGlobalPosition() GeometryMath.Vector3
func (*Node) GetGlobalRotation ¶
func (node *Node) GetGlobalRotation() []GeometryMath.EulerAngles
func (*Node) GetGlobalTransformation ¶
func (node *Node) GetGlobalTransformation() GeometryMath.Matrix4x4
func (*Node) GetGrandChildById ¶
func (*Node) GetLocalPosition ¶
func (node *Node) GetLocalPosition() GeometryMath.Vector3
func (*Node) GetLocalRotation ¶
func (node *Node) GetLocalRotation() []GeometryMath.EulerAngles
func (*Node) GetLocalTransformation ¶
func (node *Node) GetLocalTransformation() GeometryMath.Matrix4x4
func (*Node) SetLocalTransformation ¶
func (node *Node) SetLocalTransformation(matrix GeometryMath.Matrix4x4)
Click to show internal directories.
Click to hide internal directories.