Documentation
¶
Index ¶
- type Frame
- type Player
- func (p *Player) FrameChan() <-chan Frame
- func (p *Player) GetCurrentTime() time.Duration
- func (p *Player) GetDuration() time.Duration
- func (p *Player) GetPlaybackRate() float64
- func (p *Player) IsPlaying() bool
- func (p *Player) Pause()
- func (p *Player) Play()
- func (p *Player) Seek(t time.Duration)
- func (p *Player) SeekRelative(delta time.Duration)
- func (p *Player) SetPlaybackRate(rate float64)
- func (p *Player) SetWorldClient(client *WorldClient)
- func (p *Player) Start()
- func (p *Player) Stop()
- func (p *Player) TogglePlayPause()
- type TimelineReader
- type WorldClient
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Frame ¶
type Frame struct {
Timestamp time.Duration // Relative timestamp from start
Entities []*pb.Entity
BlockIdx int
}
Frame represents a single frame at a specific timestamp
type Player ¶
type Player struct {
// contains filtered or unexported fields
}
Player manages realtime playback of matroska timeline files
func (*Player) GetCurrentTime ¶
GetCurrentTime returns the current playback time
func (*Player) GetDuration ¶
GetDuration returns the total duration
func (*Player) GetPlaybackRate ¶
GetPlaybackRate returns the current playback rate
func (*Player) SeekRelative ¶
SeekRelative seeks relative to current position
func (*Player) SetPlaybackRate ¶
SetPlaybackRate sets the playback speed multiplier
func (*Player) SetWorldClient ¶
func (p *Player) SetWorldClient(client *WorldClient)
SetWorldClient sets the gRPC client for pushing entities
func (*Player) TogglePlayPause ¶
func (p *Player) TogglePlayPause()
TogglePlayPause toggles between play and pause
type TimelineReader ¶
type TimelineReader struct {
// contains filtered or unexported fields
}
TimelineReader reads timeline files
func NewTimelineReader ¶
func NewTimelineReader(path string) (*TimelineReader, error)
NewTimelineReader creates a new timeline reader
type WorldClient ¶
type WorldClient struct {
// contains filtered or unexported fields
}
WorldClient wraps the gRPC client for pushing entities
func NewWorldClient ¶
func NewWorldClient(client pb.WorldServiceClient) *WorldClient
NewWorldClient creates a new world client
func (*WorldClient) ClearOwnEntities ¶
func (wc *WorldClient) ClearOwnEntities() error
ClearOwnEntities clears all entities owned by this controller
func (*WorldClient) ListEntities ¶
func (wc *WorldClient) ListEntities(filter *pb.EntityFilter) ([]*pb.Entity, error)
ListEntities lists entities with a filter
func (*WorldClient) ListEntitiesByController ¶
func (wc *WorldClient) ListEntitiesByController(controllerId string) ([]*pb.Entity, error)
ListEntitiesByController lists entities by controller ID