Open dnjooiopa opened 3 months ago
This is out of design. It's easier just to break RTSP connection and create new one after pause.
This is out of design. It's easier just to break RTSP connection and create new one after pause.
I attempted to add a PlayWithScale
method in pkg/rtsp/client.go
and called this method instead of Play
, but the stream from the source doesn’t play at scale*X
speed. I’m not sure if I’m approaching this correctly.
func (c *Conn) PlayWithScale(scale float64) (err error) {
req := &tcp.Request{
Method: MethodPlay,
URL: c.URL,
Header: map[string][]string{
"Scale": {fmt.Sprintf("%.3f", scale)},
},
}
return c.WriteRequest(req)
}
ref: https://www.rfc-editor.org/rfc/rfc2326.html#section-12.34
This is also out of design. Go2rtc about real time. Scale is not about real time.
Can anyone suggest a method to control an RTSP source, such as sending a PLAY command with a Scale header or sending a PAUSE command?