Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/1340>
*
* The uri of the file/resource to use. You can set a start index,
* a stop index and a sequence pattern.
- * The format is <multifile://start:stop\@location-pattern>.
+ * The format is <multifile://start:stop\@location-pattern>.
* The pattern uses printf string formating.
*
* Example uris:
* gst-launch-1.0 -v videotestsrc ! videoconvert ! rsvgoverlay name=overlay ! videoconvert ! autovideosink filesrc location=foo.svg ! image/svg ! overlay.data_sink
* ]| does the same by feeding data through the data_sink pad. You can also specify the SVG data itself as parameter:
* |[
- * gst-launch-1.0 -v videotestsrc ! videoconvert ! rsvgoverlay data='<svg viewBox="0 0 800 600"><image x="80%" y="80%" width="10%" height="10%" xlink:href="foo.jpg" /></svg>' ! videoconvert ! autovideosink
+ * gst-launch-1.0 -v videotestsrc ! videoconvert ! rsvgoverlay data='<svg viewBox="0 0 800 600"><image x="80%" y="80%" width="10%" height="10%" xlink:href="foo.jpg" /></svg>' ! videoconvert ! autovideosink
* ]|
*
*/
* // pad templates should be a #GstStaticPadTemplate with direction
* // #GST_PAD_SRC and name "vidsrc", "imgsrc" and "vfsrc"
* gst_element_class_add_static_pad_template (gstelement_class,
- * &vidsrc_template);
+ * &vidsrc_template);
* gst_element_class_add_static_pad_template (gstelement_class,
- * &imgsrc_template);
+ * &imgsrc_template);
* gst_element_class_add_static_pad_template (gstelement_class,
- * &vfsrc_template);
+ * &vfsrc_template);
* // see #GstElementDetails
- * gst_element_class_set_details (gstelement_class, &details);
+ * gst_element_class_set_details (gstelement_class, &details);
* }
* ]|
*
* if you need to check at runtime what version of the gst-plugins-base
* libraries are being used / you are currently linked against.
*
- * The version macros get defined by including <gst/pbutils/pbutils.h>.
+ * The version macros get defined by including <gst/pbutils/pbutils.h>.
*/
#ifdef HAVE_CONFIG_H
#include "config.h"
* Gtk+/Gnome application should be able to obtain the XID of the top-level
* window like this:
* |[
- * ##include <gtk/gtk.h>
+ * ##include <gtk/gtk.h>
* ##ifdef GDK_WINDOWING_X11
- * ##include <gdk/gdkx.h>
+ * ##include <gdk/gdkx.h>
* ##endif
* ...
* ##ifdef GDK_WINDOWING_X11
- * xid = GDK_WINDOW_XWINDOW (GTK_WIDGET (application_window)->window);
+ * xid = GDK_WINDOW_XWINDOW (GTK_WIDGET (application_window)->window);
* ##endif
* ...
* ]|
* GstVideoFrame vframe;
* ...
* // set RGB pixels to black one at a time
- * if (gst_video_frame_map (&vframe, video_info, video_buffer, GST_MAP_WRITE)) {
+ * if (gst_video_frame_map (&vframe, video_info, video_buffer, GST_MAP_WRITE)) {
* guint8 *pixels = GST_VIDEO_FRAME_PLANE_DATA (vframe, 0);
* guint stride = GST_VIDEO_FRAME_PLANE_STRIDE (vframe, 0);
* guint pixel_stride = GST_VIDEO_FRAME_COMP_PSTRIDE (vframe, 0);
* }
* }
*
- * gst_video_frame_unmap (&vframe);
+ * gst_video_frame_unmap (&vframe);
* }
* ...
* ]|
* ## GstVideoOverlay and Gtk+
*
* |[
- * #include <gst/video/videooverlay.h>
- * #include <gtk/gtk.h>
+ * #include <gst/video/videooverlay.h>
+ * #include <gtk/gtk.h>
* #ifdef GDK_WINDOWING_X11
- * #include <gdk/gdkx.h> // for GDK_WINDOW_XID
+ * #include <gdk/gdkx.h> // for GDK_WINDOW_XID
* #endif
* #ifdef GDK_WINDOWING_WIN32
- * #include <gdk/gdkwin32.h> // for GDK_WINDOW_HWND
+ * #include <gdk/gdkwin32.h> // for GDK_WINDOW_HWND
* #endif
* ...
* static guintptr video_window_handle = 0;
* ## Example code
* |[
*
- * #include <gst/gst.h>
- * #include <gst/video/video.h>
+ * #include <gst/gst.h>
+ * #include <gst/video/video.h>
*
* ...
*
* {
* CairoOverlayState *state = (CairoOverlayState *)user_data;
*
- * gst_video_format_parse_caps (caps, NULL, &state->width, &state->height);
- * state->valid = TRUE;
+ * gst_video_format_parse_caps (caps, NULL, &state->width, &state->height);
+ * state->valid = TRUE;
* }
*
* static void
* CairoOverlayState *s = (CairoOverlayState *)user_data;
* double scale;
*
- * if (!s->valid)
+ * if (!s->valid)
* return;
*
* scale = 2*(((timestamp/(int)1e7) % 70)+30)/100.0;
- * cairo_translate(cr, s->width/2, (s->height/2)-30);
+ * cairo_translate(cr, s->width/2, (s->height/2)-30);
* cairo_scale (cr, scale, scale);
*
* cairo_move_to (cr, 0, 0);
*
* ## Example code
* |[
- * #include <gst/gst.h>
+ * #include <gst/gst.h>
*
* ...
* typedef struct {
*
* ...
*
- * for (i = 0; i < 5; i++) {
+ * for (i = 0; i < 5; i++) {
* band = gst_child_proxy_get_child_by_index (GST_CHILD_PROXY (equalizer), i);
* g_object_set (G_OBJECT (band), "freq", state[i].freq,
* "bandwidth", state[i].width,
* main (int argc, char *argv[])
* {
* GOptionEntry options[] = {
- * {"tags", 't', 0, G_OPTION_ARG_NONE, &tags,
+ * {"tags", 't', 0, G_OPTION_ARG_NONE, &tags,
* N_("Output tags (also known as metadata)"), NULL},
* {NULL}
* };
*
* ## Using an element factory
* |[<!-- language="C" -->
- * #include <gst/gst.h>
+ * #include <gst/gst.h>
*
* GstElement *src;
* GstElementFactory *srcfactory;
*
- * gst_init (&argc, &argv);
+ * gst_init (&argc, &argv);
*
* srcfactory = gst_element_factory_find ("filesrc");
* g_return_if_fail (srcfactory != NULL);
* If you must do that for some reason, there is still an option.
* If the debugging
* subsystem was compiled out, GST_DISABLE_GST_DEBUG is defined in
- * <gst/gst.h>,
+ * <gst/gst.h>,
* so you can check that before doing your trick.
* Disabling the debugging subsystem will give you a slight (read: unnoticeable)
* speed increase and will reduce the size of your compiled code. The GStreamer
* GValue item = G_VALUE_INIT;
* done = FALSE;
* while (!done) {
- * switch (gst_iterator_next (it, &item)) {
+ * switch (gst_iterator_next (it, &item)) {
* case GST_ITERATOR_OK:
* ...get/use/change item here...
- * g_value_reset (&item);
+ * g_value_reset (&item);
* break;
* case GST_ITERATOR_RESYNC:
* ...rollback changes to items...
* break;
* }
* }
- * g_value_unset (&item);
+ * g_value_unset (&item);
* gst_iterator_free (it);
* ]|
*/
* case GST_MESSAGE_TAG: {
* GstTagList *tags = NULL;
*
- * gst_message_parse_tag (msg, &tags);
+ * 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);
* case GST_MESSAGE_STATE_CHANGED: {
* GstState old_state, new_state;
*
- * gst_message_parse_state_changed (msg, &old_state, &new_state, NULL);
+ * 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),
* GError *err = NULL;
* gchar *dbg_info = NULL;
*
- * gst_message_parse_error (msg, &err, &dbg_info);
+ * 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");
* my_method (void)
* {
* GstPad *pad;
- * pad = gst_pad_new_from_static_template (&my_template, "sink");
+ * pad = gst_pad_new_from_static_template (&my_template, "sink");
* ...
* }
* ]|
* {
* GstElementClass *gstelement_class = GST_ELEMENT_CLASS (klass);
*
- * gst_element_class_add_static_pad_template (gstelement_class, &my_template);
+ * gst_element_class_add_static_pad_template (gstelement_class, &my_template);
* }
* ]|
*/
* res = gst_element_query (pipeline, query);
* if (res) {
* gint64 duration;
- * gst_query_parse_duration (query, NULL, &duration);
+ * gst_query_parse_duration (query, NULL, &duration);
* g_print ("duration = %"GST_TIME_FORMAT, GST_TIME_ARGS (duration));
* } else {
* g_print ("duration query failed...");
* my_peek (gpointer data, gint64 offset, guint size)
* {
* MyTypeFind *find = (MyTypeFind *) data;
- * if (offset >= 0 && offset + size <= find->size) {
+ * if (offset >= 0 && offset + size <= find->size) {
* return find->data + offset;
* }
* return NULL;
* my_suggest (gpointer data, guint probability, GstCaps *caps)
* {
* MyTypeFind *find = (MyTypeFind *) data;
- * if (probability > find->probability) {
+ * if (probability > find->probability) {
* find->probability = probability;
- * gst_caps_replace (&find->caps, caps);
+ * gst_caps_replace (&find->caps, caps);
* }
* }
* static GstCaps *
* {
* GList *walk, *type_list;
* MyTypeFind find = {data, size, 0, NULL};
- * GstTypeFind gst_find = {my_peek, my_suggest, &find, };
+ * GstTypeFind gst_find = {my_peek, my_suggest, &find, };
* walk = type_list = gst_type_find_factory_get_list ();
* while (walk) {
* GstTypeFindFactory *factory = GST_TYPE_FIND_FACTORY (walk->data);
* walk = g_list_next (walk)
- * gst_type_find_factory_call_function (factory, &gst_find);
+ * gst_type_find_factory_call_function (factory, &gst_find);
* }
* g_list_free (type_list);
* return find.caps;
*
* // sinktemplate should be a #GstStaticPadTemplate with direction
* // %GST_PAD_SINK and name "sink"
- * gst_element_class_add_static_pad_template (gstelement_class, &sinktemplate);
+ * gst_element_class_add_static_pad_template (gstelement_class, &sinktemplate);
*
* gst_element_class_set_static_metadata (gstelement_class,
* "Sink name",
* GstElementClass *gstelement_class = GST_ELEMENT_CLASS (klass);
* // srctemplate should be a #GstStaticPadTemplate with direction
* // %GST_PAD_SRC and name "src"
- * gst_element_class_add_static_pad_template (gstelement_class, &srctemplate);
+ * gst_element_class_add_static_pad_template (gstelement_class, &srctemplate);
*
* gst_element_class_set_static_metadata (gstelement_class,
* "Source name",