mirror of
https://github.com/go-gst/go-gst.git
synced 2025-10-06 00:17:00 +08:00
commit custom events the way it should look
This commit is contained in:
@@ -58,7 +58,7 @@ func createPipeline() (*gst.Pipeline, error) {
|
|||||||
fmt.Printf("Received custom event with count=%d send_eos=%v\n", customEvent.Count, customEvent.SendEOS)
|
fmt.Printf("Received custom event with count=%d send_eos=%v\n", customEvent.Count, customEvent.SendEOS)
|
||||||
if customEvent.SendEOS {
|
if customEvent.SendEOS {
|
||||||
fmt.Println("Send EOS is true, sending eos")
|
fmt.Println("Send EOS is true, sending eos")
|
||||||
if !pipeline.GetPipelineBus().Post(gst.NewEOSMessage(self)) {
|
if !pipeline.SendEvent(gst.NewEOSEvent()) {
|
||||||
fmt.Println("WARNING: Failed to send EOS to pipeline")
|
fmt.Println("WARNING: Failed to send EOS to pipeline")
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
|
Reference in New Issue
Block a user