Update wyoming producer and backchannel

This commit is contained in:
Alex X
2025-04-22 10:26:00 +03:00
parent df2e982090
commit 6df1e68a5f
4 changed files with 47 additions and 19 deletions
+22
View File
@@ -1,6 +1,8 @@
package wyoming
import (
"net"
"github.com/AlexxIT/go2rtc/pkg/core"
"github.com/pion/rtp"
)
@@ -10,6 +12,26 @@ type Producer struct {
api *API
}
func newProducer(conn net.Conn) *Producer {
return &Producer{
core.Connection{
ID: core.NewID(),
FormatName: "wyoming",
Medias: []*core.Media{
{
Kind: core.KindAudio,
Direction: core.DirectionRecvonly,
Codecs: []*core.Codec{
{Name: core.CodecPCML, ClockRate: 16000},
},
},
},
Transport: conn,
},
NewAPI(conn),
}
}
func (p *Producer) Start() error {
var seq uint16
var ts uint32