mirror of
https://github.com/m1k1o/neko.git
synced 2025-05-29 17:07:15 +02:00
gst: move sample channel to AttachAppsink.
This commit is contained in:
parent
fdf17cfe77
commit
009ceddbd3
3 changed files with 15 additions and 16 deletions
|
@ -13,7 +13,6 @@ import (
|
|||
type BroacastManagerCtx struct {
|
||||
logger zerolog.Logger
|
||||
mu sync.Mutex
|
||||
sampleChannel chan types.Sample
|
||||
|
||||
pipeline *gst.Pipeline
|
||||
pipelineMu sync.Mutex
|
||||
|
@ -32,7 +31,6 @@ func broadcastNew(pipelineFn func(url string) (string, error), defaultUrl string
|
|||
return &BroacastManagerCtx{
|
||||
logger: logger,
|
||||
pipelineFn: pipelineFn,
|
||||
sampleChannel: make(chan types.Sample),
|
||||
url: defaultUrl,
|
||||
started: defaultUrl != "",
|
||||
}
|
||||
|
@ -99,7 +97,7 @@ func (manager *BroacastManagerCtx) createPipeline() error {
|
|||
Str("src", pipelineStr).
|
||||
Msgf("starting pipeline")
|
||||
|
||||
manager.pipeline, err = gst.CreatePipeline(pipelineStr, manager.sampleChannel)
|
||||
manager.pipeline, err = gst.CreatePipeline(pipelineStr)
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue