Restore Announce method for RTSP

This commit is contained in:
Alexey Khit
2023-02-17 09:20:46 +03:00
parent a8612fca43
commit e43b1e4ab6
+20 -18
View File
@@ -319,24 +319,26 @@ func (c *Conn) Describe() error {
return nil return nil
} }
//func (c *Conn) Announce() (err error) { func (c *Conn) Announce() (err error) {
// req := &tcp.Request{ req := &tcp.Request{
// Method: MethodAnnounce, Method: MethodAnnounce,
// URL: c.URL, URL: c.URL,
// Header: map[string][]string{ Header: map[string][]string{
// "Content-Type": {"application/sdp"}, "Content-Type": {"application/sdp"},
// }, },
// } }
//
// //req.Body, err = c.sdp.Marshal() req.Body, err = streamer.MarshalSDP(c.SessionName, c.Medias)
// if err != nil { if err != nil {
// return return err
// } }
//
// _, err = c.Do(req) res, err := c.Do(req)
//
// return _ = res
//}
return
}
func (c *Conn) Setup() error { func (c *Conn) Setup() error {
for _, media := range c.Medias { for _, media := range c.Medias {