ffmpeg: use one command to stream video/audio
This commit is contained in:
@@ -5,6 +5,7 @@ import (
|
||||
"rkkvm/http/hw/stream"
|
||||
"rkkvm/http/middleware"
|
||||
"rkkvm/http/reqrsp"
|
||||
"time"
|
||||
|
||||
"github.com/gin-gonic/gin"
|
||||
log "github.com/sirupsen/logrus"
|
||||
@@ -70,7 +71,12 @@ func SetScreen(c *gin.Context) {
|
||||
})
|
||||
return
|
||||
}
|
||||
|
||||
log.Debug("Stopping ffmpeg SetScreen")
|
||||
ffmpeg.Stop()
|
||||
time.Sleep(100 * time.Millisecond)
|
||||
ffmpeg.ApplyOptions()
|
||||
log.Debug("Starting ffmpeg SetScreen")
|
||||
ffmpeg.Start()
|
||||
|
||||
log.Debugf("update screen: %+v", req)
|
||||
|
||||
Reference in New Issue
Block a user