Add RTSP SDP to stream info JSON

This commit is contained in:
Alexey Khit
2023-07-23 17:26:26 +03:00
parent 3defbd60db
commit e6a87fbd69
5 changed files with 20 additions and 7 deletions
+4 -1
View File
@@ -4,7 +4,6 @@ import (
"bufio"
"errors"
"fmt"
"github.com/AlexxIT/go2rtc/pkg/tcp/websocket"
"net"
"net/http"
"net/url"
@@ -12,6 +11,8 @@ import (
"strings"
"time"
"github.com/AlexxIT/go2rtc/pkg/tcp/websocket"
"github.com/AlexxIT/go2rtc/pkg/core"
"github.com/AlexxIT/go2rtc/pkg/tcp"
)
@@ -139,6 +140,8 @@ func (c *Conn) Describe() error {
}
}
c.sdp = string(res.Body) // for info
medias, err := UnmarshalSDP(res.Body)
if err != nil {
return err