Creates and appends a new entry.
The specified location string is copied. However, ownership over the tag list and structure are transferred to the message.
Returns the optional details structure of the message. May be NULL if none.
The returned structure must not be freed.
The details, or NULL if none.
the number of entries stored in the message
Retrieve the sequence number of a message.
Messages have ever-incrementing sequence numbers, which may also be set
explicitly via gst_message_set_seqnum(). Sequence numbers are typically used
to indicate that a message corresponds to some other set of messages or
events, for example a SEGMENT_DONE message corresponding to a SEEK event. It
is considered good practice to make this correspondence when possible, though
it is not required.
Note that events and messages share the same sequence number incrementor; two events or messages will never have the same sequence number unless that correspondence was made explicitly.
The message's sequence number. MT safe.
Access the structure of the message.
The structure of the message. The structure is still owned by the message, which means that you should not free it and that the pointer becomes invalid when you free the message. MT safe.
Checks if message has the given name. This function is usually used to
check the name of a custom message.
name to check
true if name matches the name of the message structure.
Extract the running_time from the async_done message.
MT safe.
Extracts the buffering percent from the GstMessage. see also
gst_message_new_buffering().
MT safe.
Extracts the buffering stats values from message.
Parse a context type from an existing GST_MESSAGE_NEED_CONTEXT message.
a gboolean indicating if the parsing succeeded.
Parses a device-added message. The device-added message is produced by Gst.DeviceProvider or a Gst.DeviceMonitor. It announces the appearance of monitored devices.
Parses a device-changed message. The device-changed message is produced by
Gst.DeviceProvider or a Gst.DeviceMonitor. It announces the
disappearance of monitored devices. * It announce that a device properties has
changed and device represents the new modified version of changed_device.
Parses a device-removed message. The device-removed message is produced by Gst.DeviceProvider or a Gst.DeviceMonitor. It announces the disappearance of monitored devices.
Extracts the GError and debug string from the GstMessage. The values returned in the output arguments are copies; the caller must free them when done.
Typical usage of this function might be:
...
switch (GST_MESSAGE_TYPE (msg)) {
case GST_MESSAGE_ERROR: {
GError *err = NULL;
gchar *dbg_info = NULL;
gst_message_parse_error (msg, &err, &dbg_info);
g_printerr ("ERROR from element %s: %s\n",
GST_OBJECT_NAME (msg->src), err->message);
g_printerr ("Debugging info: %s\n", (dbg_info) ? dbg_info : "none");
g_error_free (err);
g_free (dbg_info);
break;
}
...
}
...
MT safe.
Returns the optional details structure, may be NULL if none. The returned structure must not be freed.
Returns the details structure if present or will create one if not present. The returned structure must not be freed.
Extract the group from the STREAM_START message.
true if the message had a group id set, false otherwise MT safe.
Returns the optional details structure, may be NULL if none The returned structure must not be freed.
Returns the details structure if present or will create one if not present. The returned structure must not be freed.
Parses the rate_multiplier from the instant-rate-request message.
Parses the progress type, code and text.
Extract the timestamps and live status from the QoS message.
The returned values give the running_time, stream_time, timestamp and duration of the dropped buffer. Values of GST_CLOCK_TIME_NONE mean unknown values.
MT safe.
Extract the QoS values that have been calculated/analysed from the QoS data
MT safe.
Parses the location and/or structure from the entry with the given index.
The index must be between 0 and gst_message_get_num_redirect_entries() - 1.
Returned pointers are valid for as long as this message exists.
index of the entry to parse
Extract the running-time from the RESET_TIME message.
MT safe.
Extracts the old and new states from the GstMessage.
Typical usage of this function might be:
...
switch (GST_MESSAGE_TYPE (msg)) {
case GST_MESSAGE_STATE_CHANGED: {
GstState old_state, new_state;
gst_message_parse_state_changed (msg, &old_state, &new_state, NULL);
g_print ("Element %s changed state from %s to %s.\n",
GST_OBJECT_NAME (msg->src),
gst_element_state_get_name (old_state),
gst_element_state_get_name (new_state));
break;
}
...
}
...
MT safe.
Parses a stream-collection message.
Extracts the stream status type and owner the GstMessage. The returned
owner remains valid for as long as the reference to message is valid and
should thus not be unreffed.
MT safe.
Parses a streams-selected message.
Extracts the change type and completion status from the GstMessage.
MT safe.
Extracts the tag list from the GstMessage. The tag list returned in the output argument is a copy; the caller must free it when done.
Typical usage of this function might be:
...
switch (GST_MESSAGE_TYPE (msg)) {
case GST_MESSAGE_TAG: {
GstTagList *tags = NULL;
gst_message_parse_tag (msg, &tags);
g_print ("Got tags from element %s\n", GST_OBJECT_NAME (msg->src));
handle_tags (tags);
gst_tag_list_unref (tags);
break;
}
...
}
...
MT safe.
Extract the TOC from the Gst.Message. The TOC returned in the
output argument is a copy; the caller must free it with
gst_toc_unref() when done.
MT safe.
Returns the optional details structure, may be NULL if none The returned structure must not be freed.
Returns the details structure if present or will create one if not present. The returned structure must not be freed.
Configures the buffering stats values in message.
a buffering mode
the average input rate
the average output rate
amount of buffering time left in milliseconds
Add details to message. Will fail if the message already has details set on
it or if it is not writable.
Optionaldetails: StructureA GstStructure with details
Sets the group id on the stream-start message.
All streams that have the same group id are supposed to be played together, i.e. all streams inside a container file should have the same group id but different stream ids. The group id should change each time the stream is started, resulting in different group ids each time a file is played for example.
MT safe.
the group id
Set the QoS stats representing the history of the current continuous pipeline playback period.
When format is GST_FORMAT_UNDEFINED both dropped and processed are
invalid. Values of -1 for either processed or dropped mean unknown values.
MT safe.
Units of the 'processed' and 'dropped' fields. Video sinks and video filters will use GST_FORMAT_BUFFERS (frames). Audio sinks and audio filters will likely use GST_FORMAT_DEFAULT (samples).
Total number of units correctly processed since the last state change to READY or a flushing operation.
Total number of units dropped since the last state change to READY or a flushing operation.
Set the QoS values that have been calculated/analysed from the QoS data
MT safe.
The difference of the running-time against the deadline.
Long term prediction of the ideal rate relative to normal rate to get optimal quality.
An element dependent integer value that specifies the current quality level of the element. The default maximum quality is 1000000.
Set the sequence number of a message.
This function might be called by the creator of a message to indicate that
the message relates to other messages or events. See gst_message_get_seqnum()
for more information.
MT safe.
A sequence number.
Configures the object handling the streaming thread. This is usually a GstTask object but other objects might be added in the future.
the object controlling the streaming
Adds the stream to the message.
a Gst.Stream to add to message
Returns the number of streams contained in the message.
The number of streams contained within.
Retrieves the Gst.Stream with index index from the message.
Index of the stream to retrieve
Returns the details structure of the message. If not present it will be
created. Use this function (instead of gst_message_get_details()) if you
want to write to the details structure.
The returned structure must not be freed.
The details
Get a writable version of the structure.
The structure of the message. The structure is still owned by the message, which means that you should not free it and that the pointer becomes invalid when you free the message. This function ensures that message is writable, and if so, will never return null. MT safe.
Staticnew_Staticnew_Staticnew_Staticnew_Staticnew_Staticnew_Staticnew_Staticnew_Staticnew_Staticnew_Staticnew_Staticnew_Staticnew_Staticnew_Staticnew_Staticnew_Staticnew_Staticnew_Staticnew_Staticnew_Staticnew_Staticnew_Staticnew_Staticnew_Staticnew_Staticnew_Staticnew_Staticnew_Staticnew_Staticnew_Staticnew_Staticnew_Staticnew_Staticnew_Staticnew_Staticnew_Staticnew_Staticnew_Staticnew_Staticnew_Staticnew_Staticnew_Staticnew_StatictakeModifies a pointer to a Gst.Message to point to a different Gst.Message. This
function is similar to gst_message_replace() except that it takes ownership
of new_message.
pointer to a pointer to a Gst.Message to be replaced.
Optionalnew_message: Gst.Messagepointer to a Gst.Message that will replace the message pointed to by old_message.
Messages are implemented as a subclass of Gst.MiniObject with a generic Gst.Structure as the content. This allows for writing custom messages without requiring an API change while allowing a wide range of different types of messages.
Messages are posted by objects in the pipeline and are passed to the application using the Gst.Bus.
The basic use pattern of posting a message on a Gst.Bus is as follows:
A Gst.Element usually posts messages on the bus provided by the parent container using
gst_element_post_message().