transport

package
v0.0.0-...-c66ceb2 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jan 22, 2020 License: MIT Imports: 8 Imported by: 0

Documentation

Index

Constants

View Source
const (
	TypeStream     = "stream"
	TypeVisualizer = "visualizer"
	TypeArtNet     = "artnet"
	TypeMidi       = "midi"
	TypeBarLogger  = "barLogger"
)

transport types

Variables

This section is empty.

Functions

This section is empty.

Types

type ArtNet

type ArtNet struct {
	// contains filtered or unexported fields
}

ArtNet is a transport for the ArtNet protocol (DMX over UDP/IP)

func NewArtNet

func NewArtNet(controller art.Controller) (*ArtNet, error)

NewArtNet returns a new ArtNet transport instance

func (*ArtNet) Write

func (a *ArtNet) Write(cmd cntl.Command) error

type BarLogger

type BarLogger struct {
	// contains filtered or unexported fields
}

BarLogger logs every new bar to given logger

func NewBarLogger

func NewBarLogger(logger logger) *BarLogger

NewBarLogger returns a new logger instance

func (*BarLogger) Write

func (l *BarLogger) Write(cmd cntl.Command) error

type MIDI

type MIDI struct {
	// contains filtered or unexported fields
}

MIDI is a transport that sends MIDI signals using portmidi.

func NewMIDI

func NewMIDI(logger logging.Logger, deviceID int8) (*MIDI, error)

NewMIDI creates a new MIDI transport

func (*MIDI) Write

func (m *MIDI) Write(cmd cntl.Command) error

Write writes MIDI signals to portmidi

type Stream

type Stream struct {
	// contains filtered or unexported fields
}

Stream is an output channel that can render to a buffer

func NewStream

func NewStream(logger logging.Logger, w io.Writer) *Stream

NewStream returns a new Stream instance

func (*Stream) Write

func (b *Stream) Write(cmd cntl.Command) error

Write writes to the buffer

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL