Move callbacks out of messageRouter (#269)
* move callbacks out of messageRouter * OCD * more OCD * fix forwarder test * even more OCD * maximum OCD * package name collision, copy lock by value
This commit is contained in:
@@ -1,13 +1,13 @@
|
||||
package testutils
|
||||
|
||||
import (
|
||||
"github.com/livekit/livekit-server/pkg/sfu/buffer"
|
||||
|
||||
"github.com/pion/rtp"
|
||||
"github.com/pion/webrtc/v3"
|
||||
|
||||
"github.com/livekit/livekit-server/pkg/sfu/buffer"
|
||||
)
|
||||
|
||||
//-----------------------------------------------------------
|
||||
// -----------------------------------------------------------
|
||||
|
||||
type TestExtPacketParams struct {
|
||||
SetMarker bool
|
||||
@@ -23,7 +23,7 @@ type TestExtPacketParams struct {
|
||||
ArrivalTime int64
|
||||
}
|
||||
|
||||
//-----------------------------------------------------------
|
||||
// -----------------------------------------------------------
|
||||
|
||||
func GetTestExtPacket(params *TestExtPacketParams) (*buffer.ExtPacket, error) {
|
||||
packet := rtp.Packet{
|
||||
@@ -56,7 +56,7 @@ func GetTestExtPacket(params *TestExtPacketParams) (*buffer.ExtPacket, error) {
|
||||
return ep, nil
|
||||
}
|
||||
|
||||
//--------------------------------------
|
||||
// --------------------------------------
|
||||
|
||||
func GetTestExtPacketVP8(params *TestExtPacketParams, vp8 *buffer.VP8) (*buffer.ExtPacket, error) {
|
||||
ep, err := GetTestExtPacket(params)
|
||||
@@ -69,7 +69,7 @@ func GetTestExtPacketVP8(params *TestExtPacketParams, vp8 *buffer.VP8) (*buffer.
|
||||
return ep, nil
|
||||
}
|
||||
|
||||
//--------------------------------------
|
||||
// --------------------------------------
|
||||
|
||||
var TestVP8Codec = webrtc.RTPCodecCapability{
|
||||
MimeType: "video/vp8",
|
||||
@@ -81,4 +81,4 @@ var TestOpusCodec = webrtc.RTPCodecCapability{
|
||||
ClockRate: 48000,
|
||||
}
|
||||
|
||||
//--------------------------------------
|
||||
// --------------------------------------
|
||||
|
||||
Reference in New Issue
Block a user