rtmp: add new AMF0 encoder and encoder (#3069)

This improves performance, security and removes a dependency.
This commit is contained in:
Alessandro Ros
2024-02-24 19:11:42 +01:00
committed by GitHub
parent e06155b9b0
commit da7c5744b1
56 changed files with 1159 additions and 321 deletions

View File

@@ -5,9 +5,9 @@ import (
"testing"
"time"
"github.com/notedit/rtmp/format/flv/flvio"
"github.com/stretchr/testify/require"
"github.com/bluenviron/mediamtx/internal/protocols/rtmp/amf0"
"github.com/bluenviron/mediamtx/internal/protocols/rtmp/bytecounter"
)
@@ -70,9 +70,9 @@ var readWriterCases = []struct {
Name: "i8yythrergre",
CommandID: 56456,
Arguments: []interface{}{
flvio.AMFMap{
{K: "k1", V: "v1"},
{K: "k2", V: "v2"},
amf0.Object{
{Key: "k1", Value: "v1"},
{Key: "k2", Value: "v2"},
},
nil,
},