mirror of https://github.com/mautrix/go.git
22 lines
378 B
Go
22 lines
378 B
Go
package event
|
|
|
|
import (
|
|
"encoding/json"
|
|
)
|
|
|
|
type MSC1767Audio struct {
|
|
Duration int `json:"duration"`
|
|
Waveform []int `json:"waveform"`
|
|
}
|
|
|
|
type serializableMSC1767Audio MSC1767Audio
|
|
|
|
func (ma *MSC1767Audio) MarshalJSON() ([]byte, error) {
|
|
if ma.Waveform == nil {
|
|
ma.Waveform = []int{}
|
|
}
|
|
return json.Marshal((*serializableMSC1767Audio)(ma))
|
|
}
|
|
|
|
type MSC3245Voice struct{}
|