Skip to content

Commit

Permalink
json types
Browse files Browse the repository at this point in the history
  • Loading branch information
jrcichra committed Jul 24, 2022
1 parent dc8b24e commit a4c8020
Showing 1 changed file with 31 additions and 31 deletions.
62 changes: 31 additions & 31 deletions internal/types/types.go
Original file line number Diff line number Diff line change
Expand Up @@ -21,62 +21,62 @@ type MidiCSVRecord struct {
// }

type NoteOn struct {
Time time.Time
Channel uint8
Key uint8
Velocity uint8
Time time.Time `json:"time"`
Channel uint8 `json:"channel"`
Key uint8 `json:"key"`
Velocity uint8 `json:"velocity"`
}

type NoteOff struct {
Time time.Time
Channel uint8
Key uint8
Time time.Time `json:"time"`
Channel uint8 `json:"channel"`
Key uint8 `json:"key"`
}

type ProgramChange struct {
Time time.Time
Channel uint8
Program uint8
Time time.Time `json:"time"`
Channel uint8 `json:"channel"`
Program uint8 `json:"program"`
}

type Aftertouch struct {
Time time.Time
Channel uint8
Pressure uint8
Time time.Time `json:"time"`
Channel uint8 `json:"channel"`
Pressure uint8 `json:"pressure"`
}

type ControlChange struct {
Time time.Time
Channel uint8
Controller uint8
Value uint8
Time time.Time `json:"time"`
Channel uint8 `json:"channel"`
Controller uint8 `json:"controller"`
Value uint8 `json:"value"`
}

type NoteOffVelocity struct {
Time time.Time
Channel uint8
Key uint8
Velocity uint8
Time time.Time `json:"time"`
Channel uint8 `json:"channel"`
Key uint8 `json:"key"`
Velocity uint8 `json:"velocity"`
}

type Pitchbend struct {
Time time.Time
Channel uint8
Value int16
AbsValue uint16
Time time.Time `json:"time"`
Channel uint8 `json:"channel"`
Value int16 `json:"value"`
AbsValue uint16 `json:"absvalue"`
}

type PolyAftertouch struct {
Time time.Time
Channel uint8
Key uint8
Pressure uint8
Time time.Time `json:"time"`
Channel uint8 `json:"channel"`
Key uint8 `json:"key"`
Pressure uint8 `json:"pressure"`
}

// Raw sends raw bytes to the server
type Raw struct {
Time time.Time
Data []byte
Time time.Time `json:"time"`
Data []byte `json:"data"`
}

// Get around gob types
Expand Down

0 comments on commit a4c8020

Please sign in to comment.