moq-rs/server/internal/warp/message.go

21 lines
575 B
Go
Raw Normal View History

2022-06-29 16:17:02 +00:00
package warp
type Message struct {
2022-11-18 23:13:35 +00:00
Init *MessageInit `json:"init,omitempty"`
Segment *MessageSegment `json:"segment,omitempty"`
Debug *MessageDebug `json:"debug,omitempty"`
2022-06-29 16:17:02 +00:00
}
type MessageInit struct {
2022-11-18 23:13:35 +00:00
Id string `json:"id"` // ID of the init segment
2022-06-29 16:17:02 +00:00
}
type MessageSegment struct {
2022-11-18 23:13:35 +00:00
Init string `json:"init"` // ID of the init segment to use for this segment
Timestamp int `json:"timestamp"` // PTS of the first frame in milliseconds
2022-06-29 16:17:02 +00:00
}
2022-11-18 23:13:35 +00:00
type MessageDebug struct {
MaxBitrate int `json:"max_bitrate"` // Artificially limit the QUIC max bitrate
2022-06-29 16:17:02 +00:00
}