pull in updated glib bindings, element class fixes, update examples

This commit is contained in:
Avi Zimmerman
2021-01-19 17:40:24 +02:00
parent 9110b5dbdc
commit 4ec72c3608
6 changed files with 21 additions and 27 deletions

View File

@@ -114,6 +114,14 @@ func mainLoop(loop *glib.MainLoop, pipeline *gst.Pipeline) error {
}
}()
// When passing an object created by the bindings between scopes, there is a posibility
// the finalizer will leak and destroy your object before you are done with it. One way
// of dealing with this is by taking an additional Ref and disposing of it when you are
// done with the new scope. An alternative is to declare Keep() *after* where you know
// you will be done with the object. This instructs the runtime to defer the finalizer
// until after this point is passed in the code execution.
pipeline.Keep()
return loop.RunError()
}