mirror of
https://github.com/jwetzell/osc-go.git
synced 2026-07-26 10:28:42 +00:00
33 lines
491 B
Go
33 lines
491 B
Go
package osc
|
|
|
|
type OSCPacket interface {
|
|
ToBytes() ([]byte, error)
|
|
}
|
|
|
|
type OSCBundle struct {
|
|
Contents []OSCPacket `json:"contents"`
|
|
TimeTag OSCTimeTag `json:"timeTag"`
|
|
}
|
|
|
|
type OSCArg struct {
|
|
Value any `json:"value"`
|
|
Type string `json:"type"`
|
|
}
|
|
|
|
type OSCMessage struct {
|
|
Address string `json:"address"`
|
|
Args []OSCArg `json:"args"`
|
|
}
|
|
|
|
type OSCColor struct {
|
|
r uint8
|
|
g uint8
|
|
b uint8
|
|
a uint8
|
|
}
|
|
|
|
type OSCTimeTag struct {
|
|
seconds int32
|
|
fractionalSeconds int32
|
|
}
|