Bus.enableSyncMessageEmission

void enableSyncMessageEmission()

Instructs GStreamer to emit the "sync-message" signal after running the bus's sync handler. This function is here so that code can ensure that they can synchronously receive messages without having to affect what the bin's sync handler is.

This function may be called multiple times. To clean up, the caller is responsible for calling [gst.bus.Bus.disableSyncMessageEmission] as many times as this function is called.

While this function looks similar to [gst.bus.Bus.addSignalWatch], it is not exactly the same -- this function enables synchronous emission of signals when messages arrive; [gst.bus.Bus.addSignalWatch] adds an idle callback to pop messages off the bus asynchronously. The sync-message signal comes from the thread of whatever object posted the message; the "message" signal is marshalled to the main thread via the #GMainLoop.