Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Chords

type Chords struct {
	Type   string   `json:"type"`
	Chords [][]Note `json:"chords"`
}

type Midi

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

func NewMidi

func NewMidi() (*Midi, error)

func (*Midi) Close

func (m *Midi) Close() error

func (*Midi) Drain

func (m *Midi) Drain() error

    Drain any queued midi events.

    func (*Midi) Record

    func (m *Midi) Record(timeout int) ([][]Note, error)

      Record the user playing. Consider the recording done after timeout*250ms of no note down events.

      func (*Midi) Single

      func (m *Midi) Single(prob, next *timelearn.Problem) (int, error)

      type Note

      type Note uint8

      type NoteSlice

      type NoteSlice []Note

      func (NoteSlice) Len

      func (p NoteSlice) Len() int

      func (NoteSlice) Less

      func (p NoteSlice) Less(i, j int) bool

      func (NoteSlice) Swap

      func (p NoteSlice) Swap(i, j int)

      Source Files