blob: 976d1abfe3e2bb2fdb3b2cc10e837b0e6db33a1f [file] [log] [blame]
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>GstHarness: GStreamer 1.0 Library Reference Manual</title>
<meta name="generator" content="DocBook XSL Stylesheets V1.78.1">
<link rel="home" href="index.html" title="GStreamer 1.0 Library Reference Manual">
<link rel="up" href="gstreamer-check.html" title="GStreamer Check Unit Testing">
<link rel="prev" href="gstreamer-libs-GstStreamConsistency.html" title="GstStreamConsistency">
<link rel="next" href="GstTestClock.html" title="GstTestClock">
<meta name="generator" content="GTK-Doc V1.24 (XML mode)">
<link rel="stylesheet" href="style.css" type="text/css">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
<table class="navigation" id="top" width="100%" summary="Navigation header" cellpadding="2" cellspacing="5"><tr valign="middle">
<td width="100%" align="left" class="shortcuts">
<a href="#" class="shortcut">Top</a><span id="nav_description">  <span class="dim">|</span> 
<a href="#gstreamer-libs-GstHarness.description" class="shortcut">Description</a></span>
</td>
<td><a accesskey="h" href="index.html"><img src="home.png" width="16" height="16" border="0" alt="Home"></a></td>
<td><a accesskey="u" href="gstreamer-check.html"><img src="up.png" width="16" height="16" border="0" alt="Up"></a></td>
<td><a accesskey="p" href="gstreamer-libs-GstStreamConsistency.html"><img src="left.png" width="16" height="16" border="0" alt="Prev"></a></td>
<td><a accesskey="n" href="GstTestClock.html"><img src="right.png" width="16" height="16" border="0" alt="Next"></a></td>
</tr></table>
<div class="refentry">
<a name="gstreamer-libs-GstHarness"></a><div class="titlepage"></div>
<div class="refnamediv"><table width="100%"><tr>
<td valign="top">
<h2><span class="refentrytitle"><a name="gstreamer-libs-GstHarness.top_of_page"></a>GstHarness</span></h2>
<p>GstHarness — A test-harness for writing GStreamer unit tests</p>
</td>
<td class="gallery_image" valign="top" align="right"></td>
</tr></table></div>
<div class="refsect1">
<a name="gstreamer-libs-GstHarness.functions"></a><h2>Functions</h2>
<div class="informaltable"><table width="100%" border="0">
<colgroup>
<col width="150px" class="functions_return">
<col class="functions_name">
</colgroup>
<tbody>
<tr>
<td class="function_type">
<a class="link" href="gstreamer-libs-GstHarness.html#GstHarness" title="struct GstHarness"><span class="returnvalue">GstHarness</span></a> *
</td>
<td class="function_name">
<a class="link" href="gstreamer-libs-GstHarness.html#gst-harness-new-full" title="gst_harness_new_full ()">gst_harness_new_full</a> <span class="c_punctuation">()</span>
</td>
</tr>
<tr>
<td class="function_type">
<a class="link" href="gstreamer-libs-GstHarness.html#GstHarness" title="struct GstHarness"><span class="returnvalue">GstHarness</span></a> *
</td>
<td class="function_name">
<a class="link" href="gstreamer-libs-GstHarness.html#gst-harness-new-with-element" title="gst_harness_new_with_element ()">gst_harness_new_with_element</a> <span class="c_punctuation">()</span>
</td>
</tr>
<tr>
<td class="function_type">
<a class="link" href="gstreamer-libs-GstHarness.html#GstHarness" title="struct GstHarness"><span class="returnvalue">GstHarness</span></a> *
</td>
<td class="function_name">
<a class="link" href="gstreamer-libs-GstHarness.html#gst-harness-new-with-padnames" title="gst_harness_new_with_padnames ()">gst_harness_new_with_padnames</a> <span class="c_punctuation">()</span>
</td>
</tr>
<tr>
<td class="function_type">
<a class="link" href="gstreamer-libs-GstHarness.html#GstHarness" title="struct GstHarness"><span class="returnvalue">GstHarness</span></a> *
</td>
<td class="function_name">
<a class="link" href="gstreamer-libs-GstHarness.html#gst-harness-new-with-templates" title="gst_harness_new_with_templates ()">gst_harness_new_with_templates</a> <span class="c_punctuation">()</span>
</td>
</tr>
<tr>
<td class="function_type">
<a class="link" href="gstreamer-libs-GstHarness.html#GstHarness" title="struct GstHarness"><span class="returnvalue">GstHarness</span></a> *
</td>
<td class="function_name">
<a class="link" href="gstreamer-libs-GstHarness.html#gst-harness-new" title="gst_harness_new ()">gst_harness_new</a> <span class="c_punctuation">()</span>
</td>
</tr>
<tr>
<td class="function_type">
<a class="link" href="gstreamer-libs-GstHarness.html#GstHarness" title="struct GstHarness"><span class="returnvalue">GstHarness</span></a> *
</td>
<td class="function_name">
<a class="link" href="gstreamer-libs-GstHarness.html#gst-harness-new-parse" title="gst_harness_new_parse ()">gst_harness_new_parse</a> <span class="c_punctuation">()</span>
</td>
</tr>
<tr>
<td class="function_type">
<span class="returnvalue">void</span>
</td>
<td class="function_name">
<a class="link" href="gstreamer-libs-GstHarness.html#gst-harness-teardown" title="gst_harness_teardown ()">gst_harness_teardown</a> <span class="c_punctuation">()</span>
</td>
</tr>
<tr>
<td class="function_type">
<span class="returnvalue">void</span>
</td>
<td class="function_name">
<a class="link" href="gstreamer-libs-GstHarness.html#gst-harness-add-element-src-pad" title="gst_harness_add_element_src_pad ()">gst_harness_add_element_src_pad</a> <span class="c_punctuation">()</span>
</td>
</tr>
<tr>
<td class="function_type">
<span class="returnvalue">void</span>
</td>
<td class="function_name">
<a class="link" href="gstreamer-libs-GstHarness.html#gst-harness-add-element-sink-pad" title="gst_harness_add_element_sink_pad ()">gst_harness_add_element_sink_pad</a> <span class="c_punctuation">()</span>
</td>
</tr>
<tr>
<td class="function_type">
<span class="returnvalue">void</span>
</td>
<td class="function_name">
<a class="link" href="gstreamer-libs-GstHarness.html#gst-harness-set-src-caps" title="gst_harness_set_src_caps ()">gst_harness_set_src_caps</a> <span class="c_punctuation">()</span>
</td>
</tr>
<tr>
<td class="function_type">
<span class="returnvalue">void</span>
</td>
<td class="function_name">
<a class="link" href="gstreamer-libs-GstHarness.html#gst-harness-set-sink-caps" title="gst_harness_set_sink_caps ()">gst_harness_set_sink_caps</a> <span class="c_punctuation">()</span>
</td>
</tr>
<tr>
<td class="function_type">
<span class="returnvalue">void</span>
</td>
<td class="function_name">
<a class="link" href="gstreamer-libs-GstHarness.html#gst-harness-set-caps" title="gst_harness_set_caps ()">gst_harness_set_caps</a> <span class="c_punctuation">()</span>
</td>
</tr>
<tr>
<td class="function_type">
<span class="returnvalue">void</span>
</td>
<td class="function_name">
<a class="link" href="gstreamer-libs-GstHarness.html#gst-harness-set-src-caps-str" title="gst_harness_set_src_caps_str ()">gst_harness_set_src_caps_str</a> <span class="c_punctuation">()</span>
</td>
</tr>
<tr>
<td class="function_type">
<span class="returnvalue">void</span>
</td>
<td class="function_name">
<a class="link" href="gstreamer-libs-GstHarness.html#gst-harness-set-sink-caps-str" title="gst_harness_set_sink_caps_str ()">gst_harness_set_sink_caps_str</a> <span class="c_punctuation">()</span>
</td>
</tr>
<tr>
<td class="function_type">
<span class="returnvalue">void</span>
</td>
<td class="function_name">
<a class="link" href="gstreamer-libs-GstHarness.html#gst-harness-set-caps-str" title="gst_harness_set_caps_str ()">gst_harness_set_caps_str</a> <span class="c_punctuation">()</span>
</td>
</tr>
<tr>
<td class="function_type">
<span class="returnvalue">void</span>
</td>
<td class="function_name">
<a class="link" href="gstreamer-libs-GstHarness.html#gst-harness-use-systemclock" title="gst_harness_use_systemclock ()">gst_harness_use_systemclock</a> <span class="c_punctuation">()</span>
</td>
</tr>
<tr>
<td class="function_type">
<span class="returnvalue">void</span>
</td>
<td class="function_name">
<a class="link" href="gstreamer-libs-GstHarness.html#gst-harness-use-testclock" title="gst_harness_use_testclock ()">gst_harness_use_testclock</a> <span class="c_punctuation">()</span>
</td>
</tr>
<tr>
<td class="function_type">
<a class="link" href="GstTestClock.html" title="GstTestClock"><span class="returnvalue">GstTestClock</span></a> *
</td>
<td class="function_name">
<a class="link" href="gstreamer-libs-GstHarness.html#gst-harness-get-testclock" title="gst_harness_get_testclock ()">gst_harness_get_testclock</a> <span class="c_punctuation">()</span>
</td>
</tr>
<tr>
<td class="function_type">
<a href="https://developer.gnome.org/glib/unstable/glib-Basic-Types.html#gboolean"><span class="returnvalue">gboolean</span></a>
</td>
<td class="function_name">
<a class="link" href="gstreamer-libs-GstHarness.html#gst-harness-set-time" title="gst_harness_set_time ()">gst_harness_set_time</a> <span class="c_punctuation">()</span>
</td>
</tr>
<tr>
<td class="function_type">
<a href="https://developer.gnome.org/glib/unstable/glib-Basic-Types.html#gboolean"><span class="returnvalue">gboolean</span></a>
</td>
<td class="function_name">
<a class="link" href="gstreamer-libs-GstHarness.html#gst-harness-wait-for-clock-id-waits" title="gst_harness_wait_for_clock_id_waits ()">gst_harness_wait_for_clock_id_waits</a> <span class="c_punctuation">()</span>
</td>
</tr>
<tr>
<td class="function_type">
<a href="https://developer.gnome.org/glib/unstable/glib-Basic-Types.html#gboolean"><span class="returnvalue">gboolean</span></a>
</td>
<td class="function_name">
<a class="link" href="gstreamer-libs-GstHarness.html#gst-harness-crank-single-clock-wait" title="gst_harness_crank_single_clock_wait ()">gst_harness_crank_single_clock_wait</a> <span class="c_punctuation">()</span>
</td>
</tr>
<tr>
<td class="function_type">
<a href="https://developer.gnome.org/glib/unstable/glib-Basic-Types.html#gboolean"><span class="returnvalue">gboolean</span></a>
</td>
<td class="function_name">
<a class="link" href="gstreamer-libs-GstHarness.html#gst-harness-crank-multiple-clock-waits" title="gst_harness_crank_multiple_clock_waits ()">gst_harness_crank_multiple_clock_waits</a> <span class="c_punctuation">()</span>
</td>
</tr>
<tr>
<td class="function_type">
<span class="returnvalue">void</span>
</td>
<td class="function_name">
<a class="link" href="gstreamer-libs-GstHarness.html#gst-harness-play" title="gst_harness_play ()">gst_harness_play</a> <span class="c_punctuation">()</span>
</td>
</tr>
<tr>
<td class="function_type">
<span class="returnvalue">void</span>
</td>
<td class="function_name">
<a class="link" href="gstreamer-libs-GstHarness.html#gst-harness-set-blocking-push-mode" title="gst_harness_set_blocking_push_mode ()">gst_harness_set_blocking_push_mode</a> <span class="c_punctuation">()</span>
</td>
</tr>
<tr>
<td class="function_type">
<span class="returnvalue">void</span>
</td>
<td class="function_name">
<a class="link" href="gstreamer-libs-GstHarness.html#gst-harness-set-forwarding" title="gst_harness_set_forwarding ()">gst_harness_set_forwarding</a> <span class="c_punctuation">()</span>
</td>
</tr>
<tr>
<td class="function_type">
<a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstBuffer.html"><span class="returnvalue">GstBuffer</span></a> *
</td>
<td class="function_name">
<a class="link" href="gstreamer-libs-GstHarness.html#gst-harness-create-buffer" title="gst_harness_create_buffer ()">gst_harness_create_buffer</a> <span class="c_punctuation">()</span>
</td>
</tr>
<tr>
<td class="function_type">
<a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstPad.html#GstFlowReturn"><span class="returnvalue">GstFlowReturn</span></a>
</td>
<td class="function_name">
<a class="link" href="gstreamer-libs-GstHarness.html#gst-harness-push" title="gst_harness_push ()">gst_harness_push</a> <span class="c_punctuation">()</span>
</td>
</tr>
<tr>
<td class="function_type">
<a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstBuffer.html"><span class="returnvalue">GstBuffer</span></a> *
</td>
<td class="function_name">
<a class="link" href="gstreamer-libs-GstHarness.html#gst-harness-pull" title="gst_harness_pull ()">gst_harness_pull</a> <span class="c_punctuation">()</span>
</td>
</tr>
<tr>
<td class="function_type">
<a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstBuffer.html"><span class="returnvalue">GstBuffer</span></a> *
</td>
<td class="function_name">
<a class="link" href="gstreamer-libs-GstHarness.html#gst-harness-try-pull" title="gst_harness_try_pull ()">gst_harness_try_pull</a> <span class="c_punctuation">()</span>
</td>
</tr>
<tr>
<td class="function_type">
<a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstBuffer.html"><span class="returnvalue">GstBuffer</span></a> *
</td>
<td class="function_name">
<a class="link" href="gstreamer-libs-GstHarness.html#gst-harness-push-and-pull" title="gst_harness_push_and_pull ()">gst_harness_push_and_pull</a> <span class="c_punctuation">()</span>
</td>
</tr>
<tr>
<td class="function_type">
<a href="https://developer.gnome.org/glib/unstable/glib-Basic-Types.html#guint"><span class="returnvalue">guint</span></a>
</td>
<td class="function_name">
<a class="link" href="gstreamer-libs-GstHarness.html#gst-harness-buffers-received" title="gst_harness_buffers_received ()">gst_harness_buffers_received</a> <span class="c_punctuation">()</span>
</td>
</tr>
<tr>
<td class="function_type">
<a href="https://developer.gnome.org/glib/unstable/glib-Basic-Types.html#guint"><span class="returnvalue">guint</span></a>
</td>
<td class="function_name">
<a class="link" href="gstreamer-libs-GstHarness.html#gst-harness-buffers-in-queue" title="gst_harness_buffers_in_queue ()">gst_harness_buffers_in_queue</a> <span class="c_punctuation">()</span>
</td>
</tr>
<tr>
<td class="function_type">
<span class="returnvalue">void</span>
</td>
<td class="function_name">
<a class="link" href="gstreamer-libs-GstHarness.html#gst-harness-set-drop-buffers" title="gst_harness_set_drop_buffers ()">gst_harness_set_drop_buffers</a> <span class="c_punctuation">()</span>
</td>
</tr>
<tr>
<td class="function_type">
<span class="returnvalue">void</span>
</td>
<td class="function_name">
<a class="link" href="gstreamer-libs-GstHarness.html#gst-harness-dump-to-file" title="gst_harness_dump_to_file ()">gst_harness_dump_to_file</a> <span class="c_punctuation">()</span>
</td>
</tr>
<tr>
<td class="function_type">
<a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstClock.html#GstClockTime"><span class="returnvalue">GstClockTime</span></a>
</td>
<td class="function_name">
<a class="link" href="gstreamer-libs-GstHarness.html#gst-harness-get-last-pushed-timestamp" title="gst_harness_get_last_pushed_timestamp ()">gst_harness_get_last_pushed_timestamp</a> <span class="c_punctuation">()</span>
</td>
</tr>
<tr>
<td class="function_type">
<a href="https://developer.gnome.org/glib/unstable/glib-Basic-Types.html#gboolean"><span class="returnvalue">gboolean</span></a>
</td>
<td class="function_name">
<a class="link" href="gstreamer-libs-GstHarness.html#gst-harness-push-event" title="gst_harness_push_event ()">gst_harness_push_event</a> <span class="c_punctuation">()</span>
</td>
</tr>
<tr>
<td class="function_type">
<a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstEvent.html"><span class="returnvalue">GstEvent</span></a> *
</td>
<td class="function_name">
<a class="link" href="gstreamer-libs-GstHarness.html#gst-harness-pull-event" title="gst_harness_pull_event ()">gst_harness_pull_event</a> <span class="c_punctuation">()</span>
</td>
</tr>
<tr>
<td class="function_type">
<a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstEvent.html"><span class="returnvalue">GstEvent</span></a> *
</td>
<td class="function_name">
<a class="link" href="gstreamer-libs-GstHarness.html#gst-harness-try-pull-event" title="gst_harness_try_pull_event ()">gst_harness_try_pull_event</a> <span class="c_punctuation">()</span>
</td>
</tr>
<tr>
<td class="function_type">
<a href="https://developer.gnome.org/glib/unstable/glib-Basic-Types.html#guint"><span class="returnvalue">guint</span></a>
</td>
<td class="function_name">
<a class="link" href="gstreamer-libs-GstHarness.html#gst-harness-events-received" title="gst_harness_events_received ()">gst_harness_events_received</a> <span class="c_punctuation">()</span>
</td>
</tr>
<tr>
<td class="function_type">
<a href="https://developer.gnome.org/glib/unstable/glib-Basic-Types.html#guint"><span class="returnvalue">guint</span></a>
</td>
<td class="function_name">
<a class="link" href="gstreamer-libs-GstHarness.html#gst-harness-events-in-queue" title="gst_harness_events_in_queue ()">gst_harness_events_in_queue</a> <span class="c_punctuation">()</span>
</td>
</tr>
<tr>
<td class="function_type">
<a href="https://developer.gnome.org/glib/unstable/glib-Basic-Types.html#gboolean"><span class="returnvalue">gboolean</span></a>
</td>
<td class="function_name">
<a class="link" href="gstreamer-libs-GstHarness.html#gst-harness-push-upstream-event" title="gst_harness_push_upstream_event ()">gst_harness_push_upstream_event</a> <span class="c_punctuation">()</span>
</td>
</tr>
<tr>
<td class="function_type">
<a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstEvent.html"><span class="returnvalue">GstEvent</span></a> *
</td>
<td class="function_name">
<a class="link" href="gstreamer-libs-GstHarness.html#gst-harness-pull-upstream-event" title="gst_harness_pull_upstream_event ()">gst_harness_pull_upstream_event</a> <span class="c_punctuation">()</span>
</td>
</tr>
<tr>
<td class="function_type">
<a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstEvent.html"><span class="returnvalue">GstEvent</span></a> *
</td>
<td class="function_name">
<a class="link" href="gstreamer-libs-GstHarness.html#gst-harness-try-pull-upstream-event" title="gst_harness_try_pull_upstream_event ()">gst_harness_try_pull_upstream_event</a> <span class="c_punctuation">()</span>
</td>
</tr>
<tr>
<td class="function_type">
<a href="https://developer.gnome.org/glib/unstable/glib-Basic-Types.html#guint"><span class="returnvalue">guint</span></a>
</td>
<td class="function_name">
<a class="link" href="gstreamer-libs-GstHarness.html#gst-harness-upstream-events-received" title="gst_harness_upstream_events_received ()">gst_harness_upstream_events_received</a> <span class="c_punctuation">()</span>
</td>
</tr>
<tr>
<td class="function_type">
<a href="https://developer.gnome.org/glib/unstable/glib-Basic-Types.html#guint"><span class="returnvalue">guint</span></a>
</td>
<td class="function_name">
<a class="link" href="gstreamer-libs-GstHarness.html#gst-harness-upstream-events-in-queue" title="gst_harness_upstream_events_in_queue ()">gst_harness_upstream_events_in_queue</a> <span class="c_punctuation">()</span>
</td>
</tr>
<tr>
<td class="function_type">
<a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstClock.html#GstClockTime"><span class="returnvalue">GstClockTime</span></a>
</td>
<td class="function_name">
<a class="link" href="gstreamer-libs-GstHarness.html#gst-harness-query-latency" title="gst_harness_query_latency ()">gst_harness_query_latency</a> <span class="c_punctuation">()</span>
</td>
</tr>
<tr>
<td class="function_type">
<span class="returnvalue">void</span>
</td>
<td class="function_name">
<a class="link" href="gstreamer-libs-GstHarness.html#gst-harness-set-upstream-latency" title="gst_harness_set_upstream_latency ()">gst_harness_set_upstream_latency</a> <span class="c_punctuation">()</span>
</td>
</tr>
<tr>
<td class="function_type">
<span class="returnvalue">void</span>
</td>
<td class="function_name">
<a class="link" href="gstreamer-libs-GstHarness.html#gst-harness-set-propose-allocator" title="gst_harness_set_propose_allocator ()">gst_harness_set_propose_allocator</a> <span class="c_punctuation">()</span>
</td>
</tr>
<tr>
<td class="function_type">
<span class="returnvalue">void</span>
</td>
<td class="function_name">
<a class="link" href="gstreamer-libs-GstHarness.html#gst-harness-get-allocator" title="gst_harness_get_allocator ()">gst_harness_get_allocator</a> <span class="c_punctuation">()</span>
</td>
</tr>
<tr>
<td class="function_type">
<span class="returnvalue">void</span>
</td>
<td class="function_name">
<a class="link" href="gstreamer-libs-GstHarness.html#gst-harness-add-src" title="gst_harness_add_src ()">gst_harness_add_src</a> <span class="c_punctuation">()</span>
</td>
</tr>
<tr>
<td class="function_type">
<span class="returnvalue">void</span>
</td>
<td class="function_name">
<a class="link" href="gstreamer-libs-GstHarness.html#gst-harness-add-src-harness" title="gst_harness_add_src_harness ()">gst_harness_add_src_harness</a> <span class="c_punctuation">()</span>
</td>
</tr>
<tr>
<td class="function_type">
<span class="returnvalue">void</span>
</td>
<td class="function_name">
<a class="link" href="gstreamer-libs-GstHarness.html#gst-harness-add-src-parse" title="gst_harness_add_src_parse ()">gst_harness_add_src_parse</a> <span class="c_punctuation">()</span>
</td>
</tr>
<tr>
<td class="function_type">
<a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstPad.html#GstFlowReturn"><span class="returnvalue">GstFlowReturn</span></a>
</td>
<td class="function_name">
<a class="link" href="gstreamer-libs-GstHarness.html#gst-harness-push-from-src" title="gst_harness_push_from_src ()">gst_harness_push_from_src</a> <span class="c_punctuation">()</span>
</td>
</tr>
<tr>
<td class="function_type">
<a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstPad.html#GstFlowReturn"><span class="returnvalue">GstFlowReturn</span></a>
</td>
<td class="function_name">
<a class="link" href="gstreamer-libs-GstHarness.html#gst-harness-src-crank-and-push-many" title="gst_harness_src_crank_and_push_many ()">gst_harness_src_crank_and_push_many</a> <span class="c_punctuation">()</span>
</td>
</tr>
<tr>
<td class="function_type">
<a href="https://developer.gnome.org/glib/unstable/glib-Basic-Types.html#gboolean"><span class="returnvalue">gboolean</span></a>
</td>
<td class="function_name">
<a class="link" href="gstreamer-libs-GstHarness.html#gst-harness-src-push-event" title="gst_harness_src_push_event ()">gst_harness_src_push_event</a> <span class="c_punctuation">()</span>
</td>
</tr>
<tr>
<td class="function_type">
<span class="returnvalue">void</span>
</td>
<td class="function_name">
<a class="link" href="gstreamer-libs-GstHarness.html#gst-harness-add-sink" title="gst_harness_add_sink ()">gst_harness_add_sink</a> <span class="c_punctuation">()</span>
</td>
</tr>
<tr>
<td class="function_type">
<span class="returnvalue">void</span>
</td>
<td class="function_name">
<a class="link" href="gstreamer-libs-GstHarness.html#gst-harness-add-sink-harness" title="gst_harness_add_sink_harness ()">gst_harness_add_sink_harness</a> <span class="c_punctuation">()</span>
</td>
</tr>
<tr>
<td class="function_type">
<span class="returnvalue">void</span>
</td>
<td class="function_name">
<a class="link" href="gstreamer-libs-GstHarness.html#gst-harness-add-sink-parse" title="gst_harness_add_sink_parse ()">gst_harness_add_sink_parse</a> <span class="c_punctuation">()</span>
</td>
</tr>
<tr>
<td class="function_type">
<a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstPad.html#GstFlowReturn"><span class="returnvalue">GstFlowReturn</span></a>
</td>
<td class="function_name">
<a class="link" href="gstreamer-libs-GstHarness.html#gst-harness-push-to-sink" title="gst_harness_push_to_sink ()">gst_harness_push_to_sink</a> <span class="c_punctuation">()</span>
</td>
</tr>
<tr>
<td class="function_type">
<a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstPad.html#GstFlowReturn"><span class="returnvalue">GstFlowReturn</span></a>
</td>
<td class="function_name">
<a class="link" href="gstreamer-libs-GstHarness.html#gst-harness-sink-push-many" title="gst_harness_sink_push_many ()">gst_harness_sink_push_many</a> <span class="c_punctuation">()</span>
</td>
</tr>
<tr>
<td class="function_type">
<a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstElement.html"><span class="returnvalue">GstElement</span></a> *
</td>
<td class="function_name">
<a class="link" href="gstreamer-libs-GstHarness.html#gst-harness-find-element" title="gst_harness_find_element ()">gst_harness_find_element</a> <span class="c_punctuation">()</span>
</td>
</tr>
<tr>
<td class="function_type">
<span class="returnvalue">void</span>
</td>
<td class="function_name">
<a class="link" href="gstreamer-libs-GstHarness.html#gst-harness-set" title="gst_harness_set ()">gst_harness_set</a> <span class="c_punctuation">()</span>
</td>
</tr>
<tr>
<td class="function_type">
<span class="returnvalue">void</span>
</td>
<td class="function_name">
<a class="link" href="gstreamer-libs-GstHarness.html#gst-harness-get" title="gst_harness_get ()">gst_harness_get</a> <span class="c_punctuation">()</span>
</td>
</tr>
<tr>
<td class="function_type">
<span class="returnvalue">void</span>
</td>
<td class="function_name">
<a class="link" href="gstreamer-libs-GstHarness.html#gst-harness-add-probe" title="gst_harness_add_probe ()">gst_harness_add_probe</a> <span class="c_punctuation">()</span>
</td>
</tr>
<tr>
<td class="function_type">
<a href="https://developer.gnome.org/glib/unstable/glib-Basic-Types.html#guint"><span class="returnvalue">guint</span></a>
</td>
<td class="function_name">
<a class="link" href="gstreamer-libs-GstHarness.html#gst-harness-stress-thread-stop" title="gst_harness_stress_thread_stop ()">gst_harness_stress_thread_stop</a> <span class="c_punctuation">()</span>
</td>
</tr>
<tr>
<td class="function_type">
<a class="link" href="gstreamer-libs-GstHarness.html#GstHarnessThread" title="GstHarnessThread"><span class="returnvalue">GstHarnessThread</span></a> *
</td>
<td class="function_name">
<a class="link" href="gstreamer-libs-GstHarness.html#gst-harness-stress-custom-start" title="gst_harness_stress_custom_start ()">gst_harness_stress_custom_start</a> <span class="c_punctuation">()</span>
</td>
</tr>
<tr>
<td class="define_keyword">#define</td>
<td class="function_name">
<a class="link" href="gstreamer-libs-GstHarness.html#gst-harness-stress-statechange-start" title="gst_harness_stress_statechange_start()">gst_harness_stress_statechange_start</a><span class="c_punctuation">()</span>
</td>
</tr>
<tr>
<td class="function_type">
<a class="link" href="gstreamer-libs-GstHarness.html#GstHarnessThread" title="GstHarnessThread"><span class="returnvalue">GstHarnessThread</span></a> *
</td>
<td class="function_name">
<a class="link" href="gstreamer-libs-GstHarness.html#gst-harness-stress-statechange-start-full" title="gst_harness_stress_statechange_start_full ()">gst_harness_stress_statechange_start_full</a> <span class="c_punctuation">()</span>
</td>
</tr>
<tr>
<td class="define_keyword">#define</td>
<td class="function_name">
<a class="link" href="gstreamer-libs-GstHarness.html#gst-harness-stress-push-buffer-start" title="gst_harness_stress_push_buffer_start()">gst_harness_stress_push_buffer_start</a><span class="c_punctuation">()</span>
</td>
</tr>
<tr>
<td class="function_type">
<a class="link" href="gstreamer-libs-GstHarness.html#GstHarnessThread" title="GstHarnessThread"><span class="returnvalue">GstHarnessThread</span></a> *
</td>
<td class="function_name">
<a class="link" href="gstreamer-libs-GstHarness.html#gst-harness-stress-push-buffer-start-full" title="gst_harness_stress_push_buffer_start_full ()">gst_harness_stress_push_buffer_start_full</a> <span class="c_punctuation">()</span>
</td>
</tr>
<tr>
<td class="function_type">
<a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstBuffer.html"><span class="returnvalue">GstBuffer</span></a> *
</td>
<td class="function_name">
<span class="c_punctuation">(</span><a class="link" href="gstreamer-libs-GstHarness.html#GstHarnessPrepareBufferFunc" title="GstHarnessPrepareBufferFunc ()">*GstHarnessPrepareBufferFunc</a><span class="c_punctuation">)</span> <span class="c_punctuation">()</span>
</td>
</tr>
<tr>
<td class="define_keyword">#define</td>
<td class="function_name">
<a class="link" href="gstreamer-libs-GstHarness.html#gst-harness-stress-push-buffer-with-cb-start" title="gst_harness_stress_push_buffer_with_cb_start()">gst_harness_stress_push_buffer_with_cb_start</a><span class="c_punctuation">()</span>
</td>
</tr>
<tr>
<td class="function_type">
<a class="link" href="gstreamer-libs-GstHarness.html#GstHarnessThread" title="GstHarnessThread"><span class="returnvalue">GstHarnessThread</span></a> *
</td>
<td class="function_name">
<a class="link" href="gstreamer-libs-GstHarness.html#gst-harness-stress-push-buffer-with-cb-start-full" title="gst_harness_stress_push_buffer_with_cb_start_full ()">gst_harness_stress_push_buffer_with_cb_start_full</a> <span class="c_punctuation">()</span>
</td>
</tr>
<tr>
<td class="define_keyword">#define</td>
<td class="function_name">
<a class="link" href="gstreamer-libs-GstHarness.html#gst-harness-stress-push-event-start" title="gst_harness_stress_push_event_start()">gst_harness_stress_push_event_start</a><span class="c_punctuation">()</span>
</td>
</tr>
<tr>
<td class="function_type">
<a class="link" href="gstreamer-libs-GstHarness.html#GstHarnessThread" title="GstHarnessThread"><span class="returnvalue">GstHarnessThread</span></a> *
</td>
<td class="function_name">
<a class="link" href="gstreamer-libs-GstHarness.html#gst-harness-stress-push-event-start-full" title="gst_harness_stress_push_event_start_full ()">gst_harness_stress_push_event_start_full</a> <span class="c_punctuation">()</span>
</td>
</tr>
<tr>
<td class="define_keyword">#define</td>
<td class="function_name">
<a class="link" href="gstreamer-libs-GstHarness.html#gst-harness-stress-send-upstream-event-start" title="gst_harness_stress_send_upstream_event_start()">gst_harness_stress_send_upstream_event_start</a><span class="c_punctuation">()</span>
</td>
</tr>
<tr>
<td class="function_type">
<a class="link" href="gstreamer-libs-GstHarness.html#GstHarnessThread" title="GstHarnessThread"><span class="returnvalue">GstHarnessThread</span></a> *
</td>
<td class="function_name">
<a class="link" href="gstreamer-libs-GstHarness.html#gst-harness-stress-push-upstream-event-start-full" title="gst_harness_stress_push_upstream_event_start_full ()">gst_harness_stress_push_upstream_event_start_full</a> <span class="c_punctuation">()</span>
</td>
</tr>
<tr>
<td class="define_keyword">#define</td>
<td class="function_name">
<a class="link" href="gstreamer-libs-GstHarness.html#gst-harness-stress-property-start" title="gst_harness_stress_property_start()">gst_harness_stress_property_start</a><span class="c_punctuation">()</span>
</td>
</tr>
<tr>
<td class="function_type">
<a class="link" href="gstreamer-libs-GstHarness.html#GstHarnessThread" title="GstHarnessThread"><span class="returnvalue">GstHarnessThread</span></a> *
</td>
<td class="function_name">
<a class="link" href="gstreamer-libs-GstHarness.html#gst-harness-stress-property-start-full" title="gst_harness_stress_property_start_full ()">gst_harness_stress_property_start_full</a> <span class="c_punctuation">()</span>
</td>
</tr>
<tr>
<td class="define_keyword">#define</td>
<td class="function_name">
<a class="link" href="gstreamer-libs-GstHarness.html#gst-harness-stress-requestpad-start" title="gst_harness_stress_requestpad_start()">gst_harness_stress_requestpad_start</a><span class="c_punctuation">()</span>
</td>
</tr>
<tr>
<td class="function_type">
<a class="link" href="gstreamer-libs-GstHarness.html#GstHarnessThread" title="GstHarnessThread"><span class="returnvalue">GstHarnessThread</span></a> *
</td>
<td class="function_name">
<a class="link" href="gstreamer-libs-GstHarness.html#gst-harness-stress-requestpad-start-full" title="gst_harness_stress_requestpad_start_full ()">gst_harness_stress_requestpad_start_full</a> <span class="c_punctuation">()</span>
</td>
</tr>
</tbody>
</table></div>
</div>
<div class="refsect1">
<a name="gstreamer-libs-GstHarness.other"></a><h2>Types and Values</h2>
<div class="informaltable"><table width="100%" border="0">
<colgroup>
<col width="150px" class="name">
<col class="description">
</colgroup>
<tbody>
<tr>
<td class="datatype_keyword">struct</td>
<td class="function_name"><a class="link" href="gstreamer-libs-GstHarness.html#GstHarness" title="struct GstHarness">GstHarness</a></td>
</tr>
<tr>
<td class="datatype_keyword"> </td>
<td class="function_name"><a class="link" href="gstreamer-libs-GstHarness.html#GstHarnessThread" title="GstHarnessThread">GstHarnessThread</a></td>
</tr>
</tbody>
</table></div>
</div>
<div class="refsect1">
<a name="gstreamer-libs-GstHarness.includes"></a><h2>Includes</h2>
<pre class="synopsis">#include &lt;gst/check/check.h&gt;
</pre>
</div>
<div class="refsect1">
<a name="gstreamer-libs-GstHarness.description"></a><h2>Description</h2>
<p><a class="link" href="gstreamer-libs-GstHarness.html#GstHarness" title="struct GstHarness"><span class="type">GstHarness</span></a> is ment to make writing unit test for GStreamer much easier.
It can be though of as a way of treating a <a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstElement.html"><span class="type">GstElement</span></a> as a black box,
deterministially feeding it data, and controlling what data it outputs.</p>
<p>The basic structure of <a class="link" href="gstreamer-libs-GstHarness.html#GstHarness" title="struct GstHarness"><span class="type">GstHarness</span></a> is two "floating" <a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstPad.html"><span class="type">GstPads</span></a>, that connects
to the harnessed <a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstElement.html"><span class="type">GstElement</span></a> src and sink <a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstPad.html"><span class="type">GstPads</span></a> like so:</p>
<pre class="programlisting">
__________________________
_____ | _____ _____ | _____
| | | | | | | | | |
| src |--+-| sink| Element | src |-+--| sink|
|_____| | |_____| |_____| | |_____|
|__________________________|
</pre>
<p>With this, you can now simulate any environment the <a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstElement.html"><span class="type">GstElement</span></a> might find
itself in. By specifying the <a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstCaps.html"><span class="type">GstCaps</span></a> of the harness <a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstPad.html"><span class="type">GstPads</span></a>, using
functions like gst_harness_set_src_caps or gst_harness_set_sink_caps_str,
you can test how the <a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstElement.html"><span class="type">GstElement</span></a> interacts with different capssets.</p>
<p>Your harnessed <a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstElement.html"><span class="type">GstElement</span></a> can of course also be a bin, and using
gst_harness_new_parse supporting standard gst-launch syntax, you can
easily test a whole pipeline instead of just one element.</p>
<p>You can then go on to push <a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstBuffer.html"><span class="type">GstBuffers</span></a> and <a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstEvent.html"><span class="type">GstEvents</span></a> on to the srcpad,
using functions like gst_harness_push and gst_harness_push_event, and
then pull them out to examine them with gst_harness_pull and
gst_harness_pull_event.</p>
<div class="example">
<a name="id-1.2.7.6.6.8"></a><p class="title"><b>Example 1. A simple buffer-in buffer-out example</b></p>
<div class="example-contents">
<table class="listing_frame" border="0" cellpadding="0" cellspacing="0">
<tbody>
<tr>
<td class="listing_lines" align="right"><pre>1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27</pre></td>
<td class="listing_code"><pre class="programlisting"><span class="gtkdoc ppc">#include &lt;gst/gst.h&gt;</span>
<span class="gtkdoc ppc">#include &lt;gst/check/gstharness.h&gt;</span>
GstHarness <span class="gtkdoc opt">*</span>h<span class="gtkdoc opt">;</span>
GstBuffer <span class="gtkdoc opt">*</span>in_buf<span class="gtkdoc opt">;</span>
GstBuffer <span class="gtkdoc opt">*</span>out_buf<span class="gtkdoc opt">;</span>
<span class="gtkdoc slc">// attach the harness to the src and sink pad of GstQueue</span>
h <span class="gtkdoc opt">=</span> <span class="function"><a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer-libs/html/gstreamer-libs-GstHarness.html#gst-harness-new">gst_harness_new</a></span> <span class="gtkdoc opt">(</span><span class="string">&quot;queue&quot;</span><span class="gtkdoc opt">);</span>
<span class="gtkdoc slc">// we must specify a caps before pushing buffers</span>
<span class="function"><a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer-libs/html/gstreamer-libs-GstHarness.html#gst-harness-set-src-caps-str">gst_harness_set_src_caps_str</a></span> <span class="gtkdoc opt">(</span>h<span class="gtkdoc opt">,</span> <span class="string">&quot;mycaps&quot;</span><span class="gtkdoc opt">);</span>
<span class="gtkdoc slc">// create a buffer of size 42</span>
in_buf <span class="gtkdoc opt">=</span> <span class="function"><a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer-libs/html/gstreamer-libs-GstHarness.html#gst-harness-create-buffer">gst_harness_create_buffer</a></span> <span class="gtkdoc opt">(</span>h<span class="gtkdoc opt">,</span> <span class="number">42</span><span class="gtkdoc opt">);</span>
<span class="gtkdoc slc">// push the buffer into the queue</span>
<span class="function"><a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer-libs/html/gstreamer-libs-GstHarness.html#gst-harness-push">gst_harness_push</a></span> <span class="gtkdoc opt">(</span>h<span class="gtkdoc opt">,</span> in_buf<span class="gtkdoc opt">);</span>
<span class="gtkdoc slc">// pull the buffer from the queue</span>
out_buf <span class="gtkdoc opt">=</span> <span class="function"><a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer-libs/html/gstreamer-libs-GstHarness.html#gst-harness-pull">gst_harness_pull</a></span> <span class="gtkdoc opt">(</span>h<span class="gtkdoc opt">);</span>
<span class="gtkdoc slc">// validate the buffer in is the same as buffer out</span>
<span class="function">fail_unless</span> <span class="gtkdoc opt">(</span>in_buf <span class="gtkdoc opt">==</span> out_buf<span class="gtkdoc opt">);</span>
<span class="gtkdoc slc">// cleanup</span>
<span class="function"><a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstBuffer.html#gst-buffer-unref">gst_buffer_unref</a></span> <span class="gtkdoc opt">(</span>out_buf<span class="gtkdoc opt">);</span>
<span class="function"><a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer-libs/html/gstreamer-libs-GstHarness.html#gst-harness-teardown">gst_harness_teardown</a></span> <span class="gtkdoc opt">(</span>h<span class="gtkdoc opt">);</span></pre></td>
</tr>
</tbody>
</table>
</div>
</div>
<br class="example-break"><p>Another main feature of the <a class="link" href="gstreamer-libs-GstHarness.html#GstHarness" title="struct GstHarness"><span class="type">GstHarness</span></a> is its integration with the
<a class="link" href="GstTestClock.html" title="GstTestClock"><span class="type">GstTestClock</span></a>. Operating the <a class="link" href="GstTestClock.html" title="GstTestClock"><span class="type">GstTestClock</span></a> can be very challenging, but
<a class="link" href="gstreamer-libs-GstHarness.html#GstHarness" title="struct GstHarness"><span class="type">GstHarness</span></a> simplifies some of the most desired actions a lot, like wanting
to manually advance the clock while at the same time releasing a <a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstClock.html#GstClockID"><span class="type">GstClockID</span></a>
that is waiting, with functions like gst_harness_crank_single_clock_wait.</p>
<p><a class="link" href="gstreamer-libs-GstHarness.html#GstHarness" title="struct GstHarness"><span class="type">GstHarness</span></a> also supports sub-harnesses, as a way of generating and
validating data. A sub-harness is another <a class="link" href="gstreamer-libs-GstHarness.html#GstHarness" title="struct GstHarness"><span class="type">GstHarness</span></a> that is managed by
the "parent" harness, and can either be created by using the standard
gst_harness_new type functions directly on the (GstHarness *)-&gt;src_harness,
or using the much more convenient gst_harness_add_src or
gst_harness_add_sink_parse. If you have a decoder-element you want to test,
(like vp8dec) it can be very useful to add a src-harness with both a
src-element (videotestsrc) and an encoder (vp8enc) to feed the decoder data
with different configurations, by simply doing:</p>
<div class="example">
<a name="id-1.2.7.6.6.11"></a><p class="title"><b>Example 2. </b></p>
<div class="example-contents">
<table class="listing_frame" border="0" cellpadding="0" cellspacing="0">
<tbody>
<tr>
<td class="listing_lines" align="right"><pre>1
2</pre></td>
<td class="listing_code"><pre class="programlisting">GstHarness <span class="gtkdoc opt">*</span> h <span class="gtkdoc opt">=</span> <span class="function"><a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer-libs/html/gstreamer-libs-GstHarness.html#gst-harness-new">gst_harness_new</a></span> <span class="gtkdoc opt">(</span>h<span class="gtkdoc opt">,</span> <span class="string">&quot;vp8dec&quot;</span><span class="gtkdoc opt">);</span>
<span class="function"><a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer-libs/html/gstreamer-libs-GstHarness.html#gst-harness-add-src-parse">gst_harness_add_src_parse</a></span> <span class="gtkdoc opt">(</span>h<span class="gtkdoc opt">,</span> <span class="string">&quot;videotestsrc is-live=1 ! vp8enc&quot;</span><span class="gtkdoc opt">,</span> TRUE<span class="gtkdoc opt">);</span></pre></td>
</tr>
</tbody>
</table>
</div>
</div>
<br class="example-break"><p>and then feeding it data with:</p>
<div class="example">
<a name="id-1.2.7.6.6.13"></a><p class="title"><b>Example 3. </b></p>
<div class="example-contents">
<table class="listing_frame" border="0" cellpadding="0" cellspacing="0">
<tbody>
<tr>
<td class="listing_lines" align="right"><pre>1</pre></td>
<td class="listing_code"><pre class="programlisting"><span class="function"><a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer-libs/html/gstreamer-libs-GstHarness.html#gst-harness-push-from-src">gst_harness_push_from_src</a></span> <span class="gtkdoc opt">(</span>h<span class="gtkdoc opt">);</span></pre></td>
</tr>
</tbody>
</table>
</div>
</div>
<br class="example-break">
</div>
<div class="refsect1">
<a name="gstreamer-libs-GstHarness.functions_details"></a><h2>Functions</h2>
<div class="refsect2">
<a name="gst-harness-new-full"></a><h3>gst_harness_new_full ()</h3>
<pre class="programlisting"><a class="link" href="gstreamer-libs-GstHarness.html#GstHarness" title="struct GstHarness"><span class="returnvalue">GstHarness</span></a> *
gst_harness_new_full (<em class="parameter"><code><a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstElement.html"><span class="type">GstElement</span></a> *element</code></em>,
<em class="parameter"><code><a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstPadTemplate.html#GstStaticPadTemplate"><span class="type">GstStaticPadTemplate</span></a> *hsrc</code></em>,
<em class="parameter"><code>const <a href="https://developer.gnome.org/glib/unstable/glib-Basic-Types.html#gchar"><span class="type">gchar</span></a> *element_sinkpad_name</code></em>,
<em class="parameter"><code><a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstPadTemplate.html#GstStaticPadTemplate"><span class="type">GstStaticPadTemplate</span></a> *hsink</code></em>,
<em class="parameter"><code>const <a href="https://developer.gnome.org/glib/unstable/glib-Basic-Types.html#gchar"><span class="type">gchar</span></a> *element_srcpad_name</code></em>);</pre>
<p>Creates a new harness.</p>
<p>MT safe.</p>
<p><span class="annotation">[<acronym title="Exposed in C code, not necessarily available in other languages."><span class="acronym">skip</span></acronym>]</span></p>
<div class="refsect3">
<a name="id-1.2.7.6.7.2.7"></a><h4>Parameters</h4>
<div class="informaltable"><table width="100%" border="0">
<colgroup>
<col width="150px" class="parameters_name">
<col class="parameters_description">
<col width="200px" class="parameters_annotations">
</colgroup>
<tbody>
<tr>
<td class="parameter_name"><p>element</p></td>
<td class="parameter_description"><p>a <a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstElement.html"><span class="type">GstElement</span></a> to attach the harness to (transfer none)</p></td>
<td class="parameter_annotations"> </td>
</tr>
<tr>
<td class="parameter_name"><p>hsrc</p></td>
<td class="parameter_description"><p> a <a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstPadTemplate.html#GstStaticPadTemplate"><span class="type">GstStaticPadTemplate</span></a> describing the harness srcpad.
<a href="https://developer.gnome.org/glib/unstable/glib-Standard-Macros.html#NULL:CAPS"><code class="literal">NULL</code></a> will not create a harness srcpad. </p></td>
<td class="parameter_annotations"><span class="annotation">[<acronym title="NULL is OK, both for passing and for returning."><span class="acronym">allow-none</span></acronym>]</span></td>
</tr>
<tr>
<td class="parameter_name"><p>element_sinkpad_name</p></td>
<td class="parameter_description"><p> a <a href="https://developer.gnome.org/glib/unstable/glib-Basic-Types.html#gchar"><span class="type">gchar</span></a> with the name of the element
sinkpad that is then linked to the harness srcpad. Can be a static or request
or a sometimes pad that has been added. <a href="https://developer.gnome.org/glib/unstable/glib-Standard-Macros.html#NULL:CAPS"><code class="literal">NULL</code></a> will not get/request a sinkpad
from the element. (Like if the element is a src.). </p></td>
<td class="parameter_annotations"><span class="annotation">[<acronym title="NULL is OK, both for passing and for returning."><span class="acronym">allow-none</span></acronym>]</span></td>
</tr>
<tr>
<td class="parameter_name"><p>hsink</p></td>
<td class="parameter_description"><p> a <a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstPadTemplate.html#GstStaticPadTemplate"><span class="type">GstStaticPadTemplate</span></a> describing the harness sinkpad.
<a href="https://developer.gnome.org/glib/unstable/glib-Standard-Macros.html#NULL:CAPS"><code class="literal">NULL</code></a> will not create a harness sinkpad. </p></td>
<td class="parameter_annotations"><span class="annotation">[<acronym title="NULL is OK, both for passing and for returning."><span class="acronym">allow-none</span></acronym>]</span></td>
</tr>
<tr>
<td class="parameter_name"><p>element_srcpad_name</p></td>
<td class="parameter_description"><p> a <a href="https://developer.gnome.org/glib/unstable/glib-Basic-Types.html#gchar"><span class="type">gchar</span></a> with the name of the element
srcpad that is then linked to the harness sinkpad, similar to the
<em class="parameter"><code>element_sinkpad_name</code></em>
. </p></td>
<td class="parameter_annotations"><span class="annotation">[<acronym title="NULL is OK, both for passing and for returning."><span class="acronym">allow-none</span></acronym>]</span></td>
</tr>
</tbody>
</table></div>
</div>
<div class="refsect3">
<a name="id-1.2.7.6.7.2.8"></a><h4>Returns</h4>
<p> a <a class="link" href="gstreamer-libs-GstHarness.html#GstHarness" title="struct GstHarness"><span class="type">GstHarness</span></a>, or <a href="https://developer.gnome.org/glib/unstable/glib-Standard-Macros.html#NULL:CAPS"><code class="literal">NULL</code></a> if the harness could
not be created. </p>
<p><span class="annotation">[<acronym title="Free data after the code is done."><span class="acronym">transfer full</span></acronym>]</span></p>
</div>
<p class="since">Since: <a class="link" href="ix03.html#api-index-1.6">1.6</a></p>
</div>
<hr>
<div class="refsect2">
<a name="gst-harness-new-with-element"></a><h3>gst_harness_new_with_element ()</h3>
<pre class="programlisting"><a class="link" href="gstreamer-libs-GstHarness.html#GstHarness" title="struct GstHarness"><span class="returnvalue">GstHarness</span></a> *
gst_harness_new_with_element (<em class="parameter"><code><a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstElement.html"><span class="type">GstElement</span></a> *element</code></em>,
<em class="parameter"><code>const <a href="https://developer.gnome.org/glib/unstable/glib-Basic-Types.html#gchar"><span class="type">gchar</span></a> *element_sinkpad_name</code></em>,
<em class="parameter"><code>const <a href="https://developer.gnome.org/glib/unstable/glib-Basic-Types.html#gchar"><span class="type">gchar</span></a> *element_srcpad_name</code></em>);</pre>
<p>Creates a new harness. Works in the same way as gst_harness_new_full, only
that generic padtemplates are used for the harness src and sinkpads, which
will be sufficient in most usecases.</p>
<p>MT safe.</p>
<p><span class="annotation">[<acronym title="Exposed in C code, not necessarily available in other languages."><span class="acronym">skip</span></acronym>]</span></p>
<div class="refsect3">
<a name="id-1.2.7.6.7.3.7"></a><h4>Parameters</h4>
<div class="informaltable"><table width="100%" border="0">
<colgroup>
<col width="150px" class="parameters_name">
<col class="parameters_description">
<col width="200px" class="parameters_annotations">
</colgroup>
<tbody>
<tr>
<td class="parameter_name"><p>element</p></td>
<td class="parameter_description"><p>a <a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstElement.html"><span class="type">GstElement</span></a> to attach the harness to (transfer none)</p></td>
<td class="parameter_annotations"> </td>
</tr>
<tr>
<td class="parameter_name"><p>element_sinkpad_name</p></td>
<td class="parameter_description"><p> a <a href="https://developer.gnome.org/glib/unstable/glib-Basic-Types.html#gchar"><span class="type">gchar</span></a> with the name of the element
sinkpad that is then linked to the harness srcpad. <a href="https://developer.gnome.org/glib/unstable/glib-Standard-Macros.html#NULL:CAPS"><code class="literal">NULL</code></a> does not attach a
sinkpad. </p></td>
<td class="parameter_annotations"><span class="annotation">[<acronym title="NULL is OK, both for passing and for returning."><span class="acronym">allow-none</span></acronym>]</span></td>
</tr>
<tr>
<td class="parameter_name"><p>element_srcpad_name</p></td>
<td class="parameter_description"><p> a <a href="https://developer.gnome.org/glib/unstable/glib-Basic-Types.html#gchar"><span class="type">gchar</span></a> with the name of the element
srcpad that is then linked to the harness sinkpad. <a href="https://developer.gnome.org/glib/unstable/glib-Standard-Macros.html#NULL:CAPS"><code class="literal">NULL</code></a> does not attach a
srcpad. </p></td>
<td class="parameter_annotations"><span class="annotation">[<acronym title="NULL is OK, both for passing and for returning."><span class="acronym">allow-none</span></acronym>]</span></td>
</tr>
</tbody>
</table></div>
</div>
<div class="refsect3">
<a name="id-1.2.7.6.7.3.8"></a><h4>Returns</h4>
<p> a <a class="link" href="gstreamer-libs-GstHarness.html#GstHarness" title="struct GstHarness"><span class="type">GstHarness</span></a>, or <a href="https://developer.gnome.org/glib/unstable/glib-Standard-Macros.html#NULL:CAPS"><code class="literal">NULL</code></a> if the harness could
not be created. </p>
<p><span class="annotation">[<acronym title="Free data after the code is done."><span class="acronym">transfer full</span></acronym>]</span></p>
</div>
<p class="since">Since: <a class="link" href="ix03.html#api-index-1.6">1.6</a></p>
</div>
<hr>
<div class="refsect2">
<a name="gst-harness-new-with-padnames"></a><h3>gst_harness_new_with_padnames ()</h3>
<pre class="programlisting"><a class="link" href="gstreamer-libs-GstHarness.html#GstHarness" title="struct GstHarness"><span class="returnvalue">GstHarness</span></a> *
gst_harness_new_with_padnames (<em class="parameter"><code>const <a href="https://developer.gnome.org/glib/unstable/glib-Basic-Types.html#gchar"><span class="type">gchar</span></a> *element_name</code></em>,
<em class="parameter"><code>const <a href="https://developer.gnome.org/glib/unstable/glib-Basic-Types.html#gchar"><span class="type">gchar</span></a> *element_sinkpad_name</code></em>,
<em class="parameter"><code>const <a href="https://developer.gnome.org/glib/unstable/glib-Basic-Types.html#gchar"><span class="type">gchar</span></a> *element_srcpad_name</code></em>);</pre>
<p>Creates a new harness. Works in the same way as gst_harness_new_with_element,
except you specify the factoryname of the <a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstElement.html"><span class="type">GstElement</span></a></p>
<p>MT safe.</p>
<p><span class="annotation">[<acronym title="Exposed in C code, not necessarily available in other languages."><span class="acronym">skip</span></acronym>]</span></p>
<div class="refsect3">
<a name="id-1.2.7.6.7.4.7"></a><h4>Parameters</h4>
<div class="informaltable"><table width="100%" border="0">
<colgroup>
<col width="150px" class="parameters_name">
<col class="parameters_description">
<col width="200px" class="parameters_annotations">
</colgroup>
<tbody>
<tr>
<td class="parameter_name"><p>element_name</p></td>
<td class="parameter_description"><p>a <a href="https://developer.gnome.org/glib/unstable/glib-Basic-Types.html#gchar"><span class="type">gchar</span></a> describing the <a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstElement.html"><span class="type">GstElement</span></a> name</p></td>
<td class="parameter_annotations"> </td>
</tr>
<tr>
<td class="parameter_name"><p>element_sinkpad_name</p></td>
<td class="parameter_description"><p> a <a href="https://developer.gnome.org/glib/unstable/glib-Basic-Types.html#gchar"><span class="type">gchar</span></a> with the name of the element
sinkpad that is then linked to the harness srcpad. <a href="https://developer.gnome.org/glib/unstable/glib-Standard-Macros.html#NULL:CAPS"><code class="literal">NULL</code></a> does not attach a
sinkpad. </p></td>
<td class="parameter_annotations"><span class="annotation">[<acronym title="NULL is OK, both for passing and for returning."><span class="acronym">allow-none</span></acronym>]</span></td>
</tr>
<tr>
<td class="parameter_name"><p>element_srcpad_name</p></td>
<td class="parameter_description"><p> a <a href="https://developer.gnome.org/glib/unstable/glib-Basic-Types.html#gchar"><span class="type">gchar</span></a> with the name of the element
srcpad that is then linked to the harness sinkpad. <a href="https://developer.gnome.org/glib/unstable/glib-Standard-Macros.html#NULL:CAPS"><code class="literal">NULL</code></a> does not attach a
srcpad. </p></td>
<td class="parameter_annotations"><span class="annotation">[<acronym title="NULL is OK, both for passing and for returning."><span class="acronym">allow-none</span></acronym>]</span></td>
</tr>
</tbody>
</table></div>
</div>
<div class="refsect3">
<a name="id-1.2.7.6.7.4.8"></a><h4>Returns</h4>
<p> a <a class="link" href="gstreamer-libs-GstHarness.html#GstHarness" title="struct GstHarness"><span class="type">GstHarness</span></a>, or <a href="https://developer.gnome.org/glib/unstable/glib-Standard-Macros.html#NULL:CAPS"><code class="literal">NULL</code></a> if the harness could
not be created. </p>
<p><span class="annotation">[<acronym title="Free data after the code is done."><span class="acronym">transfer full</span></acronym>]</span></p>
</div>
<p class="since">Since: <a class="link" href="ix03.html#api-index-1.6">1.6</a></p>
</div>
<hr>
<div class="refsect2">
<a name="gst-harness-new-with-templates"></a><h3>gst_harness_new_with_templates ()</h3>
<pre class="programlisting"><a class="link" href="gstreamer-libs-GstHarness.html#GstHarness" title="struct GstHarness"><span class="returnvalue">GstHarness</span></a> *
gst_harness_new_with_templates (<em class="parameter"><code>const <a href="https://developer.gnome.org/glib/unstable/glib-Basic-Types.html#gchar"><span class="type">gchar</span></a> *element_name</code></em>,
<em class="parameter"><code><a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstPadTemplate.html#GstStaticPadTemplate"><span class="type">GstStaticPadTemplate</span></a> *hsrc</code></em>,
<em class="parameter"><code><a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstPadTemplate.html#GstStaticPadTemplate"><span class="type">GstStaticPadTemplate</span></a> *hsink</code></em>);</pre>
<p>Creates a new harness, like gst_harness_new_full, except it
assumes the <a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstElement.html"><span class="type">GstElement</span></a> sinkpad is named "sink" and srcpad is named "src"</p>
<p>MT safe.</p>
<p><span class="annotation">[<acronym title="Exposed in C code, not necessarily available in other languages."><span class="acronym">skip</span></acronym>]</span></p>
<div class="refsect3">
<a name="id-1.2.7.6.7.5.7"></a><h4>Parameters</h4>
<div class="informaltable"><table width="100%" border="0">
<colgroup>
<col width="150px" class="parameters_name">
<col class="parameters_description">
<col width="200px" class="parameters_annotations">
</colgroup>
<tbody>
<tr>
<td class="parameter_name"><p>element_name</p></td>
<td class="parameter_description"><p>a <a href="https://developer.gnome.org/glib/unstable/glib-Basic-Types.html#gchar"><span class="type">gchar</span></a> describing the <a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstElement.html"><span class="type">GstElement</span></a> name</p></td>
<td class="parameter_annotations"> </td>
</tr>
<tr>
<td class="parameter_name"><p>hsrc</p></td>
<td class="parameter_description"><p> a <a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstPadTemplate.html#GstStaticPadTemplate"><span class="type">GstStaticPadTemplate</span></a> describing the harness srcpad.
<a href="https://developer.gnome.org/glib/unstable/glib-Standard-Macros.html#NULL:CAPS"><code class="literal">NULL</code></a> will not create a harness srcpad. </p></td>
<td class="parameter_annotations"><span class="annotation">[<acronym title="NULL is OK, both for passing and for returning."><span class="acronym">allow-none</span></acronym>]</span></td>
</tr>
<tr>
<td class="parameter_name"><p>hsink</p></td>
<td class="parameter_description"><p> a <a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstPadTemplate.html#GstStaticPadTemplate"><span class="type">GstStaticPadTemplate</span></a> describing the harness sinkpad.
<a href="https://developer.gnome.org/glib/unstable/glib-Standard-Macros.html#NULL:CAPS"><code class="literal">NULL</code></a> will not create a harness sinkpad. </p></td>
<td class="parameter_annotations"><span class="annotation">[<acronym title="NULL is OK, both for passing and for returning."><span class="acronym">allow-none</span></acronym>]</span></td>
</tr>
</tbody>
</table></div>
</div>
<div class="refsect3">
<a name="id-1.2.7.6.7.5.8"></a><h4>Returns</h4>
<p> a <a class="link" href="gstreamer-libs-GstHarness.html#GstHarness" title="struct GstHarness"><span class="type">GstHarness</span></a>, or <a href="https://developer.gnome.org/glib/unstable/glib-Standard-Macros.html#NULL:CAPS"><code class="literal">NULL</code></a> if the harness could
not be created. </p>
<p><span class="annotation">[<acronym title="Free data after the code is done."><span class="acronym">transfer full</span></acronym>]</span></p>
</div>
<p class="since">Since: <a class="link" href="ix03.html#api-index-1.6">1.6</a></p>
</div>
<hr>
<div class="refsect2">
<a name="gst-harness-new"></a><h3>gst_harness_new ()</h3>
<pre class="programlisting"><a class="link" href="gstreamer-libs-GstHarness.html#GstHarness" title="struct GstHarness"><span class="returnvalue">GstHarness</span></a> *
gst_harness_new (<em class="parameter"><code>const <a href="https://developer.gnome.org/glib/unstable/glib-Basic-Types.html#gchar"><span class="type">gchar</span></a> *element_name</code></em>);</pre>
<p>Creates a new harness. Works like gst_harness_new_with_padnames, except it
assumes the <a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstElement.html"><span class="type">GstElement</span></a> sinkpad is named "sink" and srcpad is named "src"</p>
<p>MT safe.</p>
<p><span class="annotation">[<acronym title="Exposed in C code, not necessarily available in other languages."><span class="acronym">skip</span></acronym>]</span></p>
<div class="refsect3">
<a name="id-1.2.7.6.7.6.7"></a><h4>Parameters</h4>
<div class="informaltable"><table width="100%" border="0">
<colgroup>
<col width="150px" class="parameters_name">
<col class="parameters_description">
<col width="200px" class="parameters_annotations">
</colgroup>
<tbody><tr>
<td class="parameter_name"><p>element_name</p></td>
<td class="parameter_description"><p>a <a href="https://developer.gnome.org/glib/unstable/glib-Basic-Types.html#gchar"><span class="type">gchar</span></a> describing the <a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstElement.html"><span class="type">GstElement</span></a> name</p></td>
<td class="parameter_annotations"> </td>
</tr></tbody>
</table></div>
</div>
<div class="refsect3">
<a name="id-1.2.7.6.7.6.8"></a><h4>Returns</h4>
<p> a <a class="link" href="gstreamer-libs-GstHarness.html#GstHarness" title="struct GstHarness"><span class="type">GstHarness</span></a>, or <a href="https://developer.gnome.org/glib/unstable/glib-Standard-Macros.html#NULL:CAPS"><code class="literal">NULL</code></a> if the harness could
not be created. </p>
<p><span class="annotation">[<acronym title="Free data after the code is done."><span class="acronym">transfer full</span></acronym>]</span></p>
</div>
<p class="since">Since: <a class="link" href="ix03.html#api-index-1.6">1.6</a></p>
</div>
<hr>
<div class="refsect2">
<a name="gst-harness-new-parse"></a><h3>gst_harness_new_parse ()</h3>
<pre class="programlisting"><a class="link" href="gstreamer-libs-GstHarness.html#GstHarness" title="struct GstHarness"><span class="returnvalue">GstHarness</span></a> *
gst_harness_new_parse (<em class="parameter"><code>const <a href="https://developer.gnome.org/glib/unstable/glib-Basic-Types.html#gchar"><span class="type">gchar</span></a> *launchline</code></em>);</pre>
<p>Creates a new harness, parsing the <em class="parameter"><code>launchline</code></em>
and putting that in a <a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstBin.html"><span class="type">GstBin</span></a>,
and then attches the harness to the bin.</p>
<p>MT safe.</p>
<p><span class="annotation">[<acronym title="Exposed in C code, not necessarily available in other languages."><span class="acronym">skip</span></acronym>]</span></p>
<div class="refsect3">
<a name="id-1.2.7.6.7.7.7"></a><h4>Parameters</h4>
<div class="informaltable"><table width="100%" border="0">
<colgroup>
<col width="150px" class="parameters_name">
<col class="parameters_description">
<col width="200px" class="parameters_annotations">
</colgroup>
<tbody><tr>
<td class="parameter_name"><p>launchline</p></td>
<td class="parameter_description"><p>a <a href="https://developer.gnome.org/glib/unstable/glib-Basic-Types.html#gchar"><span class="type">gchar</span></a> describing a gst-launch type line</p></td>
<td class="parameter_annotations"> </td>
</tr></tbody>
</table></div>
</div>
<div class="refsect3">
<a name="id-1.2.7.6.7.7.8"></a><h4>Returns</h4>
<p> a <a class="link" href="gstreamer-libs-GstHarness.html#GstHarness" title="struct GstHarness"><span class="type">GstHarness</span></a>, or <a href="https://developer.gnome.org/glib/unstable/glib-Standard-Macros.html#NULL:CAPS"><code class="literal">NULL</code></a> if the harness could
not be created. </p>
<p><span class="annotation">[<acronym title="Free data after the code is done."><span class="acronym">transfer full</span></acronym>]</span></p>
</div>
<p class="since">Since: <a class="link" href="ix03.html#api-index-1.6">1.6</a></p>
</div>
<hr>
<div class="refsect2">
<a name="gst-harness-teardown"></a><h3>gst_harness_teardown ()</h3>
<pre class="programlisting"><span class="returnvalue">void</span>
gst_harness_teardown (<em class="parameter"><code><a class="link" href="gstreamer-libs-GstHarness.html#GstHarness" title="struct GstHarness"><span class="type">GstHarness</span></a> *h</code></em>);</pre>
<p>Tears down a <em class="parameter"><code>GstHarness</code></em>
, freeing all resources allocated using it.</p>
<p>MT safe.</p>
<div class="refsect3">
<a name="id-1.2.7.6.7.8.6"></a><h4>Parameters</h4>
<div class="informaltable"><table width="100%" border="0">
<colgroup>
<col width="150px" class="parameters_name">
<col class="parameters_description">
<col width="200px" class="parameters_annotations">
</colgroup>
<tbody><tr>
<td class="parameter_name"><p>h</p></td>
<td class="parameter_description"><p>a <a class="link" href="gstreamer-libs-GstHarness.html#GstHarness" title="struct GstHarness"><span class="type">GstHarness</span></a></p></td>
<td class="parameter_annotations"> </td>
</tr></tbody>
</table></div>
</div>
<p class="since">Since: <a class="link" href="ix03.html#api-index-1.6">1.6</a></p>
</div>
<hr>
<div class="refsect2">
<a name="gst-harness-add-element-src-pad"></a><h3>gst_harness_add_element_src_pad ()</h3>
<pre class="programlisting"><span class="returnvalue">void</span>
gst_harness_add_element_src_pad (<em class="parameter"><code><a class="link" href="gstreamer-libs-GstHarness.html#GstHarness" title="struct GstHarness"><span class="type">GstHarness</span></a> *h</code></em>,
<em class="parameter"><code><a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstPad.html"><span class="type">GstPad</span></a> *srcpad</code></em>);</pre>
<p>Links the specifed <a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstPad.html"><span class="type">GstPad</span></a> the <em class="parameter"><code>GstHarness</code></em>
sinkpad. This can be useful if
perhaps the srcpad did not exist at the time of creating the harness,
like a demuxer that provides a sometimes-pad after receiving data.</p>
<p>MT safe.</p>
<div class="refsect3">
<a name="id-1.2.7.6.7.9.6"></a><h4>Parameters</h4>
<div class="informaltable"><table width="100%" border="0">
<colgroup>
<col width="150px" class="parameters_name">
<col class="parameters_description">
<col width="200px" class="parameters_annotations">
</colgroup>
<tbody>
<tr>
<td class="parameter_name"><p>h</p></td>
<td class="parameter_description"><p>a <a class="link" href="gstreamer-libs-GstHarness.html#GstHarness" title="struct GstHarness"><span class="type">GstHarness</span></a></p></td>
<td class="parameter_annotations"> </td>
</tr>
<tr>
<td class="parameter_name"><p>srcpad</p></td>
<td class="parameter_description"><p>a <a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstPad.html"><span class="type">GstPad</span></a> to link to the harness sinkpad</p></td>
<td class="parameter_annotations"> </td>
</tr>
</tbody>
</table></div>
</div>
<p class="since">Since: <a class="link" href="ix03.html#api-index-1.6">1.6</a></p>
</div>
<hr>
<div class="refsect2">
<a name="gst-harness-add-element-sink-pad"></a><h3>gst_harness_add_element_sink_pad ()</h3>
<pre class="programlisting"><span class="returnvalue">void</span>
gst_harness_add_element_sink_pad (<em class="parameter"><code><a class="link" href="gstreamer-libs-GstHarness.html#GstHarness" title="struct GstHarness"><span class="type">GstHarness</span></a> *h</code></em>,
<em class="parameter"><code><a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstPad.html"><span class="type">GstPad</span></a> *sinkpad</code></em>);</pre>
<p>Links the specifed <a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstPad.html"><span class="type">GstPad</span></a> the <em class="parameter"><code>GstHarness</code></em>
srcpad.</p>
<p>MT safe.</p>
<div class="refsect3">
<a name="id-1.2.7.6.7.10.6"></a><h4>Parameters</h4>
<div class="informaltable"><table width="100%" border="0">
<colgroup>
<col width="150px" class="parameters_name">
<col class="parameters_description">
<col width="200px" class="parameters_annotations">
</colgroup>
<tbody>
<tr>
<td class="parameter_name"><p>h</p></td>
<td class="parameter_description"><p>a <a class="link" href="gstreamer-libs-GstHarness.html#GstHarness" title="struct GstHarness"><span class="type">GstHarness</span></a></p></td>
<td class="parameter_annotations"> </td>
</tr>
<tr>
<td class="parameter_name"><p>sinkpad</p></td>
<td class="parameter_description"><p>a <a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstPad.html"><span class="type">GstPad</span></a> to link to the harness srcpad</p></td>
<td class="parameter_annotations"> </td>
</tr>
</tbody>
</table></div>
</div>
<p class="since">Since: <a class="link" href="ix03.html#api-index-1.6">1.6</a></p>
</div>
<hr>
<div class="refsect2">
<a name="gst-harness-set-src-caps"></a><h3>gst_harness_set_src_caps ()</h3>
<pre class="programlisting"><span class="returnvalue">void</span>
gst_harness_set_src_caps (<em class="parameter"><code><a class="link" href="gstreamer-libs-GstHarness.html#GstHarness" title="struct GstHarness"><span class="type">GstHarness</span></a> *h</code></em>,
<em class="parameter"><code><a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstCaps.html"><span class="type">GstCaps</span></a> *caps</code></em>);</pre>
<p>Sets the <em class="parameter"><code>GstHarness</code></em>
srcpad caps. This must be done before any buffers
can legally be pushed from the harness to the element.</p>
<p>MT safe.</p>
<div class="refsect3">
<a name="id-1.2.7.6.7.11.6"></a><h4>Parameters</h4>
<div class="informaltable"><table width="100%" border="0">
<colgroup>
<col width="150px" class="parameters_name">
<col class="parameters_description">
<col width="200px" class="parameters_annotations">
</colgroup>
<tbody>
<tr>
<td class="parameter_name"><p>h</p></td>
<td class="parameter_description"><p>a <a class="link" href="gstreamer-libs-GstHarness.html#GstHarness" title="struct GstHarness"><span class="type">GstHarness</span></a></p></td>
<td class="parameter_annotations"> </td>
</tr>
<tr>
<td class="parameter_name"><p>caps</p></td>
<td class="parameter_description"><p> a <a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstCaps.html"><span class="type">GstCaps</span></a> to set on the harness srcpad. </p></td>
<td class="parameter_annotations"><span class="annotation">[<acronym title="Free data after the code is done."><span class="acronym">transfer full</span></acronym>]</span></td>
</tr>
</tbody>
</table></div>
</div>
<p class="since">Since: <a class="link" href="ix03.html#api-index-1.6">1.6</a></p>
</div>
<hr>
<div class="refsect2">
<a name="gst-harness-set-sink-caps"></a><h3>gst_harness_set_sink_caps ()</h3>
<pre class="programlisting"><span class="returnvalue">void</span>
gst_harness_set_sink_caps (<em class="parameter"><code><a class="link" href="gstreamer-libs-GstHarness.html#GstHarness" title="struct GstHarness"><span class="type">GstHarness</span></a> *h</code></em>,
<em class="parameter"><code><a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstCaps.html"><span class="type">GstCaps</span></a> *caps</code></em>);</pre>
<p>Sets the <em class="parameter"><code>GstHarness</code></em>
sinkpad caps.</p>
<p>MT safe.</p>
<div class="refsect3">
<a name="id-1.2.7.6.7.12.6"></a><h4>Parameters</h4>
<div class="informaltable"><table width="100%" border="0">
<colgroup>
<col width="150px" class="parameters_name">
<col class="parameters_description">
<col width="200px" class="parameters_annotations">
</colgroup>
<tbody>
<tr>
<td class="parameter_name"><p>h</p></td>
<td class="parameter_description"><p>a <a class="link" href="gstreamer-libs-GstHarness.html#GstHarness" title="struct GstHarness"><span class="type">GstHarness</span></a></p></td>
<td class="parameter_annotations"> </td>
</tr>
<tr>
<td class="parameter_name"><p>caps</p></td>
<td class="parameter_description"><p> a <a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstCaps.html"><span class="type">GstCaps</span></a> to set on the harness sinkpad. </p></td>
<td class="parameter_annotations"><span class="annotation">[<acronym title="Free data after the code is done."><span class="acronym">transfer full</span></acronym>]</span></td>
</tr>
</tbody>
</table></div>
</div>
<p class="since">Since: <a class="link" href="ix03.html#api-index-1.6">1.6</a></p>
</div>
<hr>
<div class="refsect2">
<a name="gst-harness-set-caps"></a><h3>gst_harness_set_caps ()</h3>
<pre class="programlisting"><span class="returnvalue">void</span>
gst_harness_set_caps (<em class="parameter"><code><a class="link" href="gstreamer-libs-GstHarness.html#GstHarness" title="struct GstHarness"><span class="type">GstHarness</span></a> *h</code></em>,
<em class="parameter"><code><a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstCaps.html"><span class="type">GstCaps</span></a> *in</code></em>,
<em class="parameter"><code><a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstCaps.html"><span class="type">GstCaps</span></a> *out</code></em>);</pre>
<p>Sets the <em class="parameter"><code>GstHarness</code></em>
srcpad and sinkpad caps.</p>
<p>MT safe.</p>
<div class="refsect3">
<a name="id-1.2.7.6.7.13.6"></a><h4>Parameters</h4>
<div class="informaltable"><table width="100%" border="0">
<colgroup>
<col width="150px" class="parameters_name">
<col class="parameters_description">
<col width="200px" class="parameters_annotations">
</colgroup>
<tbody>
<tr>
<td class="parameter_name"><p>h</p></td>
<td class="parameter_description"><p>a <a class="link" href="gstreamer-libs-GstHarness.html#GstHarness" title="struct GstHarness"><span class="type">GstHarness</span></a></p></td>
<td class="parameter_annotations"> </td>
</tr>
<tr>
<td class="parameter_name"><p>in</p></td>
<td class="parameter_description"><p> a <a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstCaps.html"><span class="type">GstCaps</span></a> to set on the harness srcpad. </p></td>
<td class="parameter_annotations"><span class="annotation">[<acronym title="Free data after the code is done."><span class="acronym">transfer full</span></acronym>]</span></td>
</tr>
<tr>
<td class="parameter_name"><p>out</p></td>
<td class="parameter_description"><p> a <a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstCaps.html"><span class="type">GstCaps</span></a> to set on the harness sinkpad. </p></td>
<td class="parameter_annotations"><span class="annotation">[<acronym title="Free data after the code is done."><span class="acronym">transfer full</span></acronym>]</span></td>
</tr>
</tbody>
</table></div>
</div>
<p class="since">Since: <a class="link" href="ix03.html#api-index-1.6">1.6</a></p>
</div>
<hr>
<div class="refsect2">
<a name="gst-harness-set-src-caps-str"></a><h3>gst_harness_set_src_caps_str ()</h3>
<pre class="programlisting"><span class="returnvalue">void</span>
gst_harness_set_src_caps_str (<em class="parameter"><code><a class="link" href="gstreamer-libs-GstHarness.html#GstHarness" title="struct GstHarness"><span class="type">GstHarness</span></a> *h</code></em>,
<em class="parameter"><code>const <a href="https://developer.gnome.org/glib/unstable/glib-Basic-Types.html#gchar"><span class="type">gchar</span></a> *str</code></em>);</pre>
<p>Sets the <em class="parameter"><code>GstHarness</code></em>
srcpad caps using a string. This must be done before
any buffers can legally be pushed from the harness to the element.</p>
<p>MT safe.</p>
<div class="refsect3">
<a name="id-1.2.7.6.7.14.6"></a><h4>Parameters</h4>
<div class="informaltable"><table width="100%" border="0">
<colgroup>
<col width="150px" class="parameters_name">
<col class="parameters_description">
<col width="200px" class="parameters_annotations">
</colgroup>
<tbody>
<tr>
<td class="parameter_name"><p>h</p></td>
<td class="parameter_description"><p>a <a class="link" href="gstreamer-libs-GstHarness.html#GstHarness" title="struct GstHarness"><span class="type">GstHarness</span></a></p></td>
<td class="parameter_annotations"> </td>
</tr>
<tr>
<td class="parameter_name"><p>str</p></td>
<td class="parameter_description"><p>a <em class="parameter"><code>gchar</code></em>
describing a <a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstCaps.html"><span class="type">GstCaps</span></a> to set on the harness srcpad</p></td>
<td class="parameter_annotations"> </td>
</tr>
</tbody>
</table></div>
</div>
<p class="since">Since: <a class="link" href="ix03.html#api-index-1.6">1.6</a></p>
</div>
<hr>
<div class="refsect2">
<a name="gst-harness-set-sink-caps-str"></a><h3>gst_harness_set_sink_caps_str ()</h3>
<pre class="programlisting"><span class="returnvalue">void</span>
gst_harness_set_sink_caps_str (<em class="parameter"><code><a class="link" href="gstreamer-libs-GstHarness.html#GstHarness" title="struct GstHarness"><span class="type">GstHarness</span></a> *h</code></em>,
<em class="parameter"><code>const <a href="https://developer.gnome.org/glib/unstable/glib-Basic-Types.html#gchar"><span class="type">gchar</span></a> *str</code></em>);</pre>
<p>Sets the <em class="parameter"><code>GstHarness</code></em>
sinkpad caps using a string.</p>
<p>MT safe.</p>
<div class="refsect3">
<a name="id-1.2.7.6.7.15.6"></a><h4>Parameters</h4>
<div class="informaltable"><table width="100%" border="0">
<colgroup>
<col width="150px" class="parameters_name">
<col class="parameters_description">
<col width="200px" class="parameters_annotations">
</colgroup>
<tbody>
<tr>
<td class="parameter_name"><p>h</p></td>
<td class="parameter_description"><p>a <a class="link" href="gstreamer-libs-GstHarness.html#GstHarness" title="struct GstHarness"><span class="type">GstHarness</span></a></p></td>
<td class="parameter_annotations"> </td>
</tr>
<tr>
<td class="parameter_name"><p>str</p></td>
<td class="parameter_description"><p>a <em class="parameter"><code>gchar</code></em>
describing a <a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstCaps.html"><span class="type">GstCaps</span></a> to set on the harness sinkpad</p></td>
<td class="parameter_annotations"> </td>
</tr>
</tbody>
</table></div>
</div>
<p class="since">Since: <a class="link" href="ix03.html#api-index-1.6">1.6</a></p>
</div>
<hr>
<div class="refsect2">
<a name="gst-harness-set-caps-str"></a><h3>gst_harness_set_caps_str ()</h3>
<pre class="programlisting"><span class="returnvalue">void</span>
gst_harness_set_caps_str (<em class="parameter"><code><a class="link" href="gstreamer-libs-GstHarness.html#GstHarness" title="struct GstHarness"><span class="type">GstHarness</span></a> *h</code></em>,
<em class="parameter"><code>const <a href="https://developer.gnome.org/glib/unstable/glib-Basic-Types.html#gchar"><span class="type">gchar</span></a> *in</code></em>,
<em class="parameter"><code>const <a href="https://developer.gnome.org/glib/unstable/glib-Basic-Types.html#gchar"><span class="type">gchar</span></a> *out</code></em>);</pre>
<p>Sets the <em class="parameter"><code>GstHarness</code></em>
srcpad and sinkpad caps using strings.</p>
<p>MT safe.</p>
<div class="refsect3">
<a name="id-1.2.7.6.7.16.6"></a><h4>Parameters</h4>
<div class="informaltable"><table width="100%" border="0">
<colgroup>
<col width="150px" class="parameters_name">
<col class="parameters_description">
<col width="200px" class="parameters_annotations">
</colgroup>
<tbody>
<tr>
<td class="parameter_name"><p>h</p></td>
<td class="parameter_description"><p>a <a class="link" href="gstreamer-libs-GstHarness.html#GstHarness" title="struct GstHarness"><span class="type">GstHarness</span></a></p></td>
<td class="parameter_annotations"> </td>
</tr>
<tr>
<td class="parameter_name"><p>in</p></td>
<td class="parameter_description"><p>a <em class="parameter"><code>gchar</code></em>
describing a <a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstCaps.html"><span class="type">GstCaps</span></a> to set on the harness srcpad</p></td>
<td class="parameter_annotations"> </td>
</tr>
<tr>
<td class="parameter_name"><p>out</p></td>
<td class="parameter_description"><p>a <em class="parameter"><code>gchar</code></em>
describing a <a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstCaps.html"><span class="type">GstCaps</span></a> to set on the harness sinkpad</p></td>
<td class="parameter_annotations"> </td>
</tr>
</tbody>
</table></div>
</div>
<p class="since">Since: <a class="link" href="ix03.html#api-index-1.6">1.6</a></p>
</div>
<hr>
<div class="refsect2">
<a name="gst-harness-use-systemclock"></a><h3>gst_harness_use_systemclock ()</h3>
<pre class="programlisting"><span class="returnvalue">void</span>
gst_harness_use_systemclock (<em class="parameter"><code><a class="link" href="gstreamer-libs-GstHarness.html#GstHarness" title="struct GstHarness"><span class="type">GstHarness</span></a> *h</code></em>);</pre>
<p>Sets the system <a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstClock.html"><span class="type">GstClock</span></a> on the <em class="parameter"><code>GstHarness</code></em>
<a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstElement.html"><span class="type">GstElement</span></a></p>
<p>MT safe.</p>
<div class="refsect3">
<a name="id-1.2.7.6.7.17.6"></a><h4>Parameters</h4>
<div class="informaltable"><table width="100%" border="0">
<colgroup>
<col width="150px" class="parameters_name">
<col class="parameters_description">
<col width="200px" class="parameters_annotations">
</colgroup>
<tbody><tr>
<td class="parameter_name"><p>h</p></td>
<td class="parameter_description"><p>a <a class="link" href="gstreamer-libs-GstHarness.html#GstHarness" title="struct GstHarness"><span class="type">GstHarness</span></a></p></td>
<td class="parameter_annotations"> </td>
</tr></tbody>
</table></div>
</div>
<p class="since">Since: <a class="link" href="ix03.html#api-index-1.6">1.6</a></p>
</div>
<hr>
<div class="refsect2">
<a name="gst-harness-use-testclock"></a><h3>gst_harness_use_testclock ()</h3>
<pre class="programlisting"><span class="returnvalue">void</span>
gst_harness_use_testclock (<em class="parameter"><code><a class="link" href="gstreamer-libs-GstHarness.html#GstHarness" title="struct GstHarness"><span class="type">GstHarness</span></a> *h</code></em>);</pre>
<p>Sets the <a class="link" href="GstTestClock.html" title="GstTestClock"><span class="type">GstTestClock</span></a> on the <a class="link" href="gstreamer-libs-GstHarness.html#GstHarness" title="struct GstHarness"><span class="type">GstHarness</span></a> <a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstElement.html"><span class="type">GstElement</span></a></p>
<p>MT safe.</p>
<div class="refsect3">
<a name="id-1.2.7.6.7.18.6"></a><h4>Parameters</h4>
<div class="informaltable"><table width="100%" border="0">
<colgroup>
<col width="150px" class="parameters_name">
<col class="parameters_description">
<col width="200px" class="parameters_annotations">
</colgroup>
<tbody><tr>
<td class="parameter_name"><p>h</p></td>
<td class="parameter_description"><p>a <a class="link" href="gstreamer-libs-GstHarness.html#GstHarness" title="struct GstHarness"><span class="type">GstHarness</span></a></p></td>
<td class="parameter_annotations"> </td>
</tr></tbody>
</table></div>
</div>
<p class="since">Since: <a class="link" href="ix03.html#api-index-1.6">1.6</a></p>
</div>
<hr>
<div class="refsect2">
<a name="gst-harness-get-testclock"></a><h3>gst_harness_get_testclock ()</h3>
<pre class="programlisting"><a class="link" href="GstTestClock.html" title="GstTestClock"><span class="returnvalue">GstTestClock</span></a> *
gst_harness_get_testclock (<em class="parameter"><code><a class="link" href="gstreamer-libs-GstHarness.html#GstHarness" title="struct GstHarness"><span class="type">GstHarness</span></a> *h</code></em>);</pre>
<p>Get the <a class="link" href="GstTestClock.html" title="GstTestClock"><span class="type">GstTestClock</span></a>. Useful if specific operations on the testclock is
needed.</p>
<p>MT safe.</p>
<div class="refsect3">
<a name="id-1.2.7.6.7.19.6"></a><h4>Parameters</h4>
<div class="informaltable"><table width="100%" border="0">
<colgroup>
<col width="150px" class="parameters_name">
<col class="parameters_description">
<col width="200px" class="parameters_annotations">
</colgroup>
<tbody><tr>
<td class="parameter_name"><p>h</p></td>
<td class="parameter_description"><p>a <a class="link" href="gstreamer-libs-GstHarness.html#GstHarness" title="struct GstHarness"><span class="type">GstHarness</span></a></p></td>
<td class="parameter_annotations"> </td>
</tr></tbody>
</table></div>
</div>
<div class="refsect3">
<a name="id-1.2.7.6.7.19.7"></a><h4>Returns</h4>
<p> a <a class="link" href="GstTestClock.html" title="GstTestClock"><span class="type">GstTestClock</span></a>, or <a href="https://developer.gnome.org/glib/unstable/glib-Standard-Macros.html#NULL:CAPS"><code class="literal">NULL</code></a> if the testclock is not
present. </p>
<p><span class="annotation">[<acronym title="Free data after the code is done."><span class="acronym">transfer full</span></acronym>]</span></p>
</div>
<p class="since">Since: <a class="link" href="ix03.html#api-index-1.6">1.6</a></p>
</div>
<hr>
<div class="refsect2">
<a name="gst-harness-set-time"></a><h3>gst_harness_set_time ()</h3>
<pre class="programlisting"><a href="https://developer.gnome.org/glib/unstable/glib-Basic-Types.html#gboolean"><span class="returnvalue">gboolean</span></a>
gst_harness_set_time (<em class="parameter"><code><a class="link" href="gstreamer-libs-GstHarness.html#GstHarness" title="struct GstHarness"><span class="type">GstHarness</span></a> *h</code></em>,
<em class="parameter"><code><a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstClock.html#GstClockTime"><span class="type">GstClockTime</span></a> time</code></em>);</pre>
<p>Advance the <a class="link" href="GstTestClock.html" title="GstTestClock"><span class="type">GstTestClock</span></a> to a specific time.</p>
<p>MT safe.</p>
<div class="refsect3">
<a name="id-1.2.7.6.7.20.6"></a><h4>Parameters</h4>
<div class="informaltable"><table width="100%" border="0">
<colgroup>
<col width="150px" class="parameters_name">
<col class="parameters_description">
<col width="200px" class="parameters_annotations">
</colgroup>
<tbody>
<tr>
<td class="parameter_name"><p>h</p></td>
<td class="parameter_description"><p>a <a class="link" href="gstreamer-libs-GstHarness.html#GstHarness" title="struct GstHarness"><span class="type">GstHarness</span></a></p></td>
<td class="parameter_annotations"> </td>
</tr>
<tr>
<td class="parameter_name"><p>time</p></td>
<td class="parameter_description"><p>a <a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstClock.html#GstClockTime"><span class="type">GstClockTime</span></a> to advance the clock to</p></td>
<td class="parameter_annotations"> </td>
</tr>
</tbody>
</table></div>
</div>
<div class="refsect3">
<a name="id-1.2.7.6.7.20.7"></a><h4>Returns</h4>
<p> a <em class="parameter"><code>gboolean</code></em>
<a href="https://developer.gnome.org/glib/unstable/glib-Standard-Macros.html#TRUE:CAPS"><code class="literal">TRUE</code></a> if the time could be set. <a href="https://developer.gnome.org/glib/unstable/glib-Standard-Macros.html#FALSE:CAPS"><code class="literal">FALSE</code></a> if not.</p>
</div>
<p class="since">Since: <a class="link" href="ix03.html#api-index-1.6">1.6</a></p>
</div>
<hr>
<div class="refsect2">
<a name="gst-harness-wait-for-clock-id-waits"></a><h3>gst_harness_wait_for_clock_id_waits ()</h3>
<pre class="programlisting"><a href="https://developer.gnome.org/glib/unstable/glib-Basic-Types.html#gboolean"><span class="returnvalue">gboolean</span></a>
gst_harness_wait_for_clock_id_waits (<em class="parameter"><code><a class="link" href="gstreamer-libs-GstHarness.html#GstHarness" title="struct GstHarness"><span class="type">GstHarness</span></a> *h</code></em>,
<em class="parameter"><code><a href="https://developer.gnome.org/glib/unstable/glib-Basic-Types.html#guint"><span class="type">guint</span></a> waits</code></em>,
<em class="parameter"><code><a href="https://developer.gnome.org/glib/unstable/glib-Basic-Types.html#guint"><span class="type">guint</span></a> timeout</code></em>);</pre>
<p>Waits for <em class="parameter"><code>timeout</code></em>
seconds until <em class="parameter"><code>waits</code></em>
number of <a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstClock.html#GstClockID"><span class="type">GstClockID</span></a> waits is
registered with the <a class="link" href="GstTestClock.html" title="GstTestClock"><span class="type">GstTestClock</span></a>. Useful for writing deterministic tests,
where you want to make sure that an expected number of waits have been
reached.</p>
<p>MT safe.</p>
<div class="refsect3">
<a name="id-1.2.7.6.7.21.6"></a><h4>Parameters</h4>
<div class="informaltable"><table width="100%" border="0">
<colgroup>
<col width="150px" class="parameters_name">
<col class="parameters_description">
<col width="200px" class="parameters_annotations">
</colgroup>
<tbody>
<tr>
<td class="parameter_name"><p>h</p></td>
<td class="parameter_description"><p>a <a class="link" href="gstreamer-libs-GstHarness.html#GstHarness" title="struct GstHarness"><span class="type">GstHarness</span></a></p></td>
<td class="parameter_annotations"> </td>
</tr>
<tr>
<td class="parameter_name"><p>waits</p></td>
<td class="parameter_description"><p>a <a href="https://developer.gnome.org/glib/unstable/glib-Basic-Types.html#guint"><span class="type">guint</span></a> describing the numbers of <a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstClock.html#GstClockID"><span class="type">GstClockID</span></a> registered with
the <a class="link" href="GstTestClock.html" title="GstTestClock"><span class="type">GstTestClock</span></a></p></td>
<td class="parameter_annotations"> </td>
</tr>
<tr>
<td class="parameter_name"><p>timeout</p></td>
<td class="parameter_description"><p>a <a href="https://developer.gnome.org/glib/unstable/glib-Basic-Types.html#guint"><span class="type">guint</span></a> describing how many seconds to wait for <em class="parameter"><code>waits</code></em>
to be true</p></td>
<td class="parameter_annotations"> </td>
</tr>
</tbody>
</table></div>
</div>
<div class="refsect3">
<a name="id-1.2.7.6.7.21.7"></a><h4>Returns</h4>
<p> a <em class="parameter"><code>gboolean</code></em>
<a href="https://developer.gnome.org/glib/unstable/glib-Standard-Macros.html#TRUE:CAPS"><code class="literal">TRUE</code></a> if the waits have been registered, <a href="https://developer.gnome.org/glib/unstable/glib-Standard-Macros.html#FALSE:CAPS"><code class="literal">FALSE</code></a> if not.
(Could be that it timed out waiting or that more waits then waits was found)</p>
</div>
<p class="since">Since: <a class="link" href="ix03.html#api-index-1.6">1.6</a></p>
</div>
<hr>
<div class="refsect2">
<a name="gst-harness-crank-single-clock-wait"></a><h3>gst_harness_crank_single_clock_wait ()</h3>
<pre class="programlisting"><a href="https://developer.gnome.org/glib/unstable/glib-Basic-Types.html#gboolean"><span class="returnvalue">gboolean</span></a>
gst_harness_crank_single_clock_wait (<em class="parameter"><code><a class="link" href="gstreamer-libs-GstHarness.html#GstHarness" title="struct GstHarness"><span class="type">GstHarness</span></a> *h</code></em>);</pre>
<p>A "crank" consists of three steps:
1: Wait for a <a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstClock.html#GstClockID"><span class="type">GstClockID</span></a> to be registered with the <a class="link" href="GstTestClock.html" title="GstTestClock"><span class="type">GstTestClock</span></a>.
2: Advance the <a class="link" href="GstTestClock.html" title="GstTestClock"><span class="type">GstTestClock</span></a> to the time the <a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstClock.html#GstClockID"><span class="type">GstClockID</span></a> is waiting for.
3: Release the <a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstClock.html#GstClockID"><span class="type">GstClockID</span></a> wait.
Together, this provides an easy way to not have to think about the details
around clocks and time, but still being able to write deterministic tests
that are dependant on this. A "crank" can be though of as the notion of
manually driving the clock forward to its next logical step.</p>
<p>MT safe.</p>
<div class="refsect3">
<a name="id-1.2.7.6.7.22.6"></a><h4>Parameters</h4>
<div class="informaltable"><table width="100%" border="0">
<colgroup>
<col width="150px" class="parameters_name">
<col class="parameters_description">
<col width="200px" class="parameters_annotations">
</colgroup>
<tbody><tr>
<td class="parameter_name"><p>h</p></td>
<td class="parameter_description"><p>a <a class="link" href="gstreamer-libs-GstHarness.html#GstHarness" title="struct GstHarness"><span class="type">GstHarness</span></a></p></td>
<td class="parameter_annotations"> </td>
</tr></tbody>
</table></div>
</div>
<div class="refsect3">
<a name="id-1.2.7.6.7.22.7"></a><h4>Returns</h4>
<p> a <em class="parameter"><code>gboolean</code></em>
<a href="https://developer.gnome.org/glib/unstable/glib-Standard-Macros.html#TRUE:CAPS"><code class="literal">TRUE</code></a> if the "crank" was successful, <a href="https://developer.gnome.org/glib/unstable/glib-Standard-Macros.html#FALSE:CAPS"><code class="literal">FALSE</code></a> if not.</p>
</div>
<p class="since">Since: <a class="link" href="ix03.html#api-index-1.6">1.6</a></p>
</div>
<hr>
<div class="refsect2">
<a name="gst-harness-crank-multiple-clock-waits"></a><h3>gst_harness_crank_multiple_clock_waits ()</h3>
<pre class="programlisting"><a href="https://developer.gnome.org/glib/unstable/glib-Basic-Types.html#gboolean"><span class="returnvalue">gboolean</span></a>
gst_harness_crank_multiple_clock_waits
(<em class="parameter"><code><a class="link" href="gstreamer-libs-GstHarness.html#GstHarness" title="struct GstHarness"><span class="type">GstHarness</span></a> *h</code></em>,
<em class="parameter"><code><a href="https://developer.gnome.org/glib/unstable/glib-Basic-Types.html#guint"><span class="type">guint</span></a> waits</code></em>);</pre>
<p>Similar to gst_harness_crank_single_clock_wait, this is the function to use
if your harnessed element(s) are using more then one gst_clock_id_wait.
Failing to do so can (and will) make it racy which <a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstClock.html#GstClockID"><span class="type">GstClockID</span></a> you actually
are releasing, where as this function will process all the waits at the
same time, ensuring that one thread can't register another wait before
both are released.</p>
<p>MT safe.</p>
<div class="refsect3">
<a name="id-1.2.7.6.7.23.6"></a><h4>Parameters</h4>
<div class="informaltable"><table width="100%" border="0">
<colgroup>
<col width="150px" class="parameters_name">
<col class="parameters_description">
<col width="200px" class="parameters_annotations">
</colgroup>
<tbody>
<tr>
<td class="parameter_name"><p>h</p></td>
<td class="parameter_description"><p>a <a class="link" href="gstreamer-libs-GstHarness.html#GstHarness" title="struct GstHarness"><span class="type">GstHarness</span></a></p></td>
<td class="parameter_annotations"> </td>
</tr>
<tr>
<td class="parameter_name"><p>waits</p></td>
<td class="parameter_description"><p>a <a href="https://developer.gnome.org/glib/unstable/glib-Basic-Types.html#guint"><span class="type">guint</span></a> describing the number of <a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstClock.html#GstClockID"><span class="type">GstClockIDs</span></a> to crank</p></td>
<td class="parameter_annotations"> </td>
</tr>
</tbody>
</table></div>
</div>
<div class="refsect3">
<a name="id-1.2.7.6.7.23.7"></a><h4>Returns</h4>
<p> a <em class="parameter"><code>gboolean</code></em>
<a href="https://developer.gnome.org/glib/unstable/glib-Standard-Macros.html#TRUE:CAPS"><code class="literal">TRUE</code></a> if the "crank" was successful, <a href="https://developer.gnome.org/glib/unstable/glib-Standard-Macros.html#FALSE:CAPS"><code class="literal">FALSE</code></a> if not.</p>
</div>
<p class="since">Since: <a class="link" href="ix03.html#api-index-1.6">1.6</a></p>
</div>
<hr>
<div class="refsect2">
<a name="gst-harness-play"></a><h3>gst_harness_play ()</h3>
<pre class="programlisting"><span class="returnvalue">void</span>
gst_harness_play (<em class="parameter"><code><a class="link" href="gstreamer-libs-GstHarness.html#GstHarness" title="struct GstHarness"><span class="type">GstHarness</span></a> *h</code></em>);</pre>
<p>This will set the harnessed <a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstElement.html"><span class="type">GstElement</span></a> to <a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstElement.html#GST-STATE-PLAYING:CAPS"><code class="literal">GST_STATE_PLAYING</code></a>.
<a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstElement.html"><span class="type">GstElements</span></a> without a sink-<a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstPad.html"><span class="type">GstPad</span></a> and with the <a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstElement.html#GST-ELEMENT-FLAG-SOURCE:CAPS"><code class="literal">GST_ELEMENT_FLAG_SOURCE</code></a>
flag set is concidered a src <a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstElement.html"><span class="type">GstElement</span></a>
Non-src <a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstElement.html"><span class="type">GstElements</span></a> (like sinks and filters) are automatically set to
playing by the <a class="link" href="gstreamer-libs-GstHarness.html#GstHarness" title="struct GstHarness"><span class="type">GstHarness</span></a>, but src <a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstElement.html"><span class="type">GstElements</span></a> are not to avoid them
starting to produce buffers.
Hence, for src <a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstElement.html"><span class="type">GstElement</span></a> you will need to call gst_harness_play explicitly.</p>
<p>MT safe.</p>
<div class="refsect3">
<a name="id-1.2.7.6.7.24.6"></a><h4>Parameters</h4>
<div class="informaltable"><table width="100%" border="0">
<colgroup>
<col width="150px" class="parameters_name">
<col class="parameters_description">
<col width="200px" class="parameters_annotations">
</colgroup>
<tbody><tr>
<td class="parameter_name"><p>h</p></td>
<td class="parameter_description"><p>a <a class="link" href="gstreamer-libs-GstHarness.html#GstHarness" title="struct GstHarness"><span class="type">GstHarness</span></a></p></td>
<td class="parameter_annotations"> </td>
</tr></tbody>
</table></div>
</div>
<p class="since">Since: <a class="link" href="ix03.html#api-index-1.6">1.6</a></p>
</div>
<hr>
<div class="refsect2">
<a name="gst-harness-set-blocking-push-mode"></a><h3>gst_harness_set_blocking_push_mode ()</h3>
<pre class="programlisting"><span class="returnvalue">void</span>
gst_harness_set_blocking_push_mode (<em class="parameter"><code><a class="link" href="gstreamer-libs-GstHarness.html#GstHarness" title="struct GstHarness"><span class="type">GstHarness</span></a> *h</code></em>);</pre>
<p>Setting this will make the harness block in the chain-function, and
then release when gst_harness_pull or gst_harness_try_pull is called.
Can be useful when wanting to control a src-element that is not implementing
gst_clock_id_wait so it can't be controlled by the <a class="link" href="GstTestClock.html" title="GstTestClock"><span class="type">GstTestClock</span></a>, since
it otherwise would produce buffers as fast as possible.</p>
<p>MT safe.</p>
<div class="refsect3">
<a name="id-1.2.7.6.7.25.6"></a><h4>Parameters</h4>
<div class="informaltable"><table width="100%" border="0">
<colgroup>
<col width="150px" class="parameters_name">
<col class="parameters_description">
<col width="200px" class="parameters_annotations">
</colgroup>
<tbody><tr>
<td class="parameter_name"><p>h</p></td>
<td class="parameter_description"><p>a <a class="link" href="gstreamer-libs-GstHarness.html#GstHarness" title="struct GstHarness"><span class="type">GstHarness</span></a></p></td>
<td class="parameter_annotations"> </td>
</tr></tbody>
</table></div>
</div>
<p class="since">Since: <a class="link" href="ix03.html#api-index-1.6">1.6</a></p>
</div>
<hr>
<div class="refsect2">
<a name="gst-harness-set-forwarding"></a><h3>gst_harness_set_forwarding ()</h3>
<pre class="programlisting"><span class="returnvalue">void</span>
gst_harness_set_forwarding (<em class="parameter"><code><a class="link" href="gstreamer-libs-GstHarness.html#GstHarness" title="struct GstHarness"><span class="type">GstHarness</span></a> *h</code></em>,
<em class="parameter"><code><a href="https://developer.gnome.org/glib/unstable/glib-Basic-Types.html#gboolean"><span class="type">gboolean</span></a> forwarding</code></em>);</pre>
<p>As a convenience, a src-harness will forward <a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstEvent.html#GST-EVENT-STREAM-START:CAPS"><code class="literal">GST_EVENT_STREAM_START</code></a>,
<a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstEvent.html#GST-EVENT-CAPS"><code class="literal">GST_EVENT_CAPS</code></a> and <a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstEvent.html#GST-EVENT-SEGMENT:CAPS"><code class="literal">GST_EVENT_SEGMENT</code></a> to the main-harness if forwarding
is enabled, and forward any sticky-events from the main-harness to
the sink-harness. It will also forward the <a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstQuery.html#GST-QUERY-ALLOCATION:CAPS"><code class="literal">GST_QUERY_ALLOCATION</code></a>.</p>
<p>If forwarding is disabled, the user will have to either manually push
these events from the src-harness using gst_harness_src_push_event, or
create and push them manually. While this will allow full control and
inspection of these events, for the most cases having forwarding enabled
will be sufficient when writing a test where the src-harness' main function
is providing data for the main-harness.</p>
<p>Forwarding is enabled by default.</p>
<p>MT safe.</p>
<div class="refsect3">
<a name="id-1.2.7.6.7.26.8"></a><h4>Parameters</h4>
<div class="informaltable"><table width="100%" border="0">
<colgroup>
<col width="150px" class="parameters_name">
<col class="parameters_description">
<col width="200px" class="parameters_annotations">
</colgroup>
<tbody>
<tr>
<td class="parameter_name"><p>h</p></td>
<td class="parameter_description"><p>a <a class="link" href="gstreamer-libs-GstHarness.html#GstHarness" title="struct GstHarness"><span class="type">GstHarness</span></a></p></td>
<td class="parameter_annotations"> </td>
</tr>
<tr>
<td class="parameter_name"><p>forwarding</p></td>
<td class="parameter_description"><p>a <a href="https://developer.gnome.org/glib/unstable/glib-Basic-Types.html#gboolean"><span class="type">gboolean</span></a> to enable/disable forwarding</p></td>
<td class="parameter_annotations"> </td>
</tr>
</tbody>
</table></div>
</div>
<p class="since">Since: <a class="link" href="ix03.html#api-index-1.6">1.6</a></p>
</div>
<hr>
<div class="refsect2">
<a name="gst-harness-create-buffer"></a><h3>gst_harness_create_buffer ()</h3>
<pre class="programlisting"><a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstBuffer.html"><span class="returnvalue">GstBuffer</span></a> *
gst_harness_create_buffer (<em class="parameter"><code><a class="link" href="gstreamer-libs-GstHarness.html#GstHarness" title="struct GstHarness"><span class="type">GstHarness</span></a> *h</code></em>,
<em class="parameter"><code><span class="type">gsize</span> size</code></em>);</pre>
<p>Allocates a buffer using a <a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstBufferPool.html"><span class="type">GstBufferPool</span></a> if present, or else using the
configured <a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstAllocator.html"><span class="type">GstAllocator</span></a> and <a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstAllocator.html#GstAllocationParams"><span class="type">GstAllocationParams</span></a></p>
<p>MT safe.</p>
<div class="refsect3">
<a name="id-1.2.7.6.7.27.6"></a><h4>Parameters</h4>
<div class="informaltable"><table width="100%" border="0">
<colgroup>
<col width="150px" class="parameters_name">
<col class="parameters_description">
<col width="200px" class="parameters_annotations">
</colgroup>
<tbody>
<tr>
<td class="parameter_name"><p>h</p></td>
<td class="parameter_description"><p>a <a class="link" href="gstreamer-libs-GstHarness.html#GstHarness" title="struct GstHarness"><span class="type">GstHarness</span></a></p></td>
<td class="parameter_annotations"> </td>
</tr>
<tr>
<td class="parameter_name"><p>size</p></td>
<td class="parameter_description"><p>a <span class="type">gsize</span> specifying the size of the buffer</p></td>
<td class="parameter_annotations"> </td>
</tr>
</tbody>
</table></div>
</div>
<div class="refsect3">
<a name="id-1.2.7.6.7.27.7"></a><h4>Returns</h4>
<p> a <a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstBuffer.html"><span class="type">GstBuffer</span></a> of size <em class="parameter"><code>size</code></em>
</p>
</div>
<p class="since">Since: <a class="link" href="ix03.html#api-index-1.6">1.6</a></p>
</div>
<hr>
<div class="refsect2">
<a name="gst-harness-push"></a><h3>gst_harness_push ()</h3>
<pre class="programlisting"><a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstPad.html#GstFlowReturn"><span class="returnvalue">GstFlowReturn</span></a>
gst_harness_push (<em class="parameter"><code><a class="link" href="gstreamer-libs-GstHarness.html#GstHarness" title="struct GstHarness"><span class="type">GstHarness</span></a> *h</code></em>,
<em class="parameter"><code><a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstBuffer.html"><span class="type">GstBuffer</span></a> *buffer</code></em>);</pre>
<p>Pushes a <a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstBuffer.html"><span class="type">GstBuffer</span></a> on the <a class="link" href="gstreamer-libs-GstHarness.html#GstHarness" title="struct GstHarness"><span class="type">GstHarness</span></a> srcpad. The standard way of
interacting with an harnessed element.</p>
<p>MT safe.</p>
<div class="refsect3">
<a name="id-1.2.7.6.7.28.6"></a><h4>Parameters</h4>
<div class="informaltable"><table width="100%" border="0">
<colgroup>
<col width="150px" class="parameters_name">
<col class="parameters_description">
<col width="200px" class="parameters_annotations">
</colgroup>
<tbody>
<tr>
<td class="parameter_name"><p>h</p></td>
<td class="parameter_description"><p>a <a class="link" href="gstreamer-libs-GstHarness.html#GstHarness" title="struct GstHarness"><span class="type">GstHarness</span></a></p></td>
<td class="parameter_annotations"> </td>
</tr>
<tr>
<td class="parameter_name"><p>buffer</p></td>
<td class="parameter_description"><p>a <a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstBuffer.html"><span class="type">GstBuffer</span></a> to push</p></td>
<td class="parameter_annotations"> </td>
</tr>
</tbody>
</table></div>
</div>
<div class="refsect3">
<a name="id-1.2.7.6.7.28.7"></a><h4>Returns</h4>
<p> a <a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstPad.html#GstFlowReturn"><span class="type">GstFlowReturn</span></a> with the result from the push</p>
</div>
<p class="since">Since: <a class="link" href="ix03.html#api-index-1.6">1.6</a></p>
</div>
<hr>
<div class="refsect2">
<a name="gst-harness-pull"></a><h3>gst_harness_pull ()</h3>
<pre class="programlisting"><a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstBuffer.html"><span class="returnvalue">GstBuffer</span></a> *
gst_harness_pull (<em class="parameter"><code><a class="link" href="gstreamer-libs-GstHarness.html#GstHarness" title="struct GstHarness"><span class="type">GstHarness</span></a> *h</code></em>);</pre>
<p>Pulls a <a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstBuffer.html"><span class="type">GstBuffer</span></a> from the <a href="https://developer.gnome.org/glib/unstable/glib-Asynchronous-Queues.html#GAsyncQueue"><span class="type">GAsyncQueue</span></a> on the <a class="link" href="gstreamer-libs-GstHarness.html#GstHarness" title="struct GstHarness"><span class="type">GstHarness</span></a> sinkpad. The pull
will timeout in 60 seconds. This is the standard way of getting a buffer
from a harnessed <a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstElement.html"><span class="type">GstElement</span></a>.</p>
<p>MT safe.</p>
<div class="refsect3">
<a name="id-1.2.7.6.7.29.6"></a><h4>Parameters</h4>
<div class="informaltable"><table width="100%" border="0">
<colgroup>
<col width="150px" class="parameters_name">
<col class="parameters_description">
<col width="200px" class="parameters_annotations">
</colgroup>
<tbody><tr>
<td class="parameter_name"><p>h</p></td>
<td class="parameter_description"><p>a <a class="link" href="gstreamer-libs-GstHarness.html#GstHarness" title="struct GstHarness"><span class="type">GstHarness</span></a></p></td>
<td class="parameter_annotations"> </td>
</tr></tbody>
</table></div>
</div>
<div class="refsect3">
<a name="id-1.2.7.6.7.29.7"></a><h4>Returns</h4>
<p> a <a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstBuffer.html"><span class="type">GstBuffer</span></a> or <a href="https://developer.gnome.org/glib/unstable/glib-Standard-Macros.html#NULL:CAPS"><code class="literal">NULL</code></a> if timed out.</p>
</div>
<p class="since">Since: <a class="link" href="ix03.html#api-index-1.6">1.6</a></p>
</div>
<hr>
<div class="refsect2">
<a name="gst-harness-try-pull"></a><h3>gst_harness_try_pull ()</h3>
<pre class="programlisting"><a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstBuffer.html"><span class="returnvalue">GstBuffer</span></a> *
gst_harness_try_pull (<em class="parameter"><code><a class="link" href="gstreamer-libs-GstHarness.html#GstHarness" title="struct GstHarness"><span class="type">GstHarness</span></a> *h</code></em>);</pre>
<p>Pulls a <a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstBuffer.html"><span class="type">GstBuffer</span></a> from the <a href="https://developer.gnome.org/glib/unstable/glib-Asynchronous-Queues.html#GAsyncQueue"><span class="type">GAsyncQueue</span></a> on the <a class="link" href="gstreamer-libs-GstHarness.html#GstHarness" title="struct GstHarness"><span class="type">GstHarness</span></a> sinkpad. Unlike
gst_harness_pull this will not wait for any buffers if not any are present,
and return <a href="https://developer.gnome.org/glib/unstable/glib-Standard-Macros.html#NULL:CAPS"><code class="literal">NULL</code></a> straight away.</p>
<p>MT safe.</p>
<div class="refsect3">
<a name="id-1.2.7.6.7.30.6"></a><h4>Parameters</h4>
<div class="informaltable"><table width="100%" border="0">
<colgroup>
<col width="150px" class="parameters_name">
<col class="parameters_description">
<col width="200px" class="parameters_annotations">
</colgroup>
<tbody><tr>
<td class="parameter_name"><p>h</p></td>
<td class="parameter_description"><p>a <a class="link" href="gstreamer-libs-GstHarness.html#GstHarness" title="struct GstHarness"><span class="type">GstHarness</span></a></p></td>
<td class="parameter_annotations"> </td>
</tr></tbody>
</table></div>
</div>
<div class="refsect3">
<a name="id-1.2.7.6.7.30.7"></a><h4>Returns</h4>
<p> a <a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstBuffer.html"><span class="type">GstBuffer</span></a> or <a href="https://developer.gnome.org/glib/unstable/glib-Standard-Macros.html#NULL:CAPS"><code class="literal">NULL</code></a> if no buffers are present in the <a href="https://developer.gnome.org/glib/unstable/glib-Asynchronous-Queues.html#GAsyncQueue"><span class="type">GAsyncQueue</span></a></p>
</div>
<p class="since">Since: <a class="link" href="ix03.html#api-index-1.6">1.6</a></p>
</div>
<hr>
<div class="refsect2">
<a name="gst-harness-push-and-pull"></a><h3>gst_harness_push_and_pull ()</h3>
<pre class="programlisting"><a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstBuffer.html"><span class="returnvalue">GstBuffer</span></a> *
gst_harness_push_and_pull (<em class="parameter"><code><a class="link" href="gstreamer-libs-GstHarness.html#GstHarness" title="struct GstHarness"><span class="type">GstHarness</span></a> *h</code></em>,
<em class="parameter"><code><a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstBuffer.html"><span class="type">GstBuffer</span></a> *buffer</code></em>);</pre>
<p>Basically a gst_harness_push and a gst_harness_pull in one line. Reflects
the fact that you often want to do exactly this in your test: Push one buffer
in, and inspect the outcome.</p>
<p>MT safe.</p>
<div class="refsect3">
<a name="id-1.2.7.6.7.31.6"></a><h4>Parameters</h4>
<div class="informaltable"><table width="100%" border="0">
<colgroup>
<col width="150px" class="parameters_name">
<col class="parameters_description">
<col width="200px" class="parameters_annotations">
</colgroup>
<tbody>
<tr>
<td class="parameter_name"><p>h</p></td>
<td class="parameter_description"><p>a <a class="link" href="gstreamer-libs-GstHarness.html#GstHarness" title="struct GstHarness"><span class="type">GstHarness</span></a></p></td>
<td class="parameter_annotations"> </td>
</tr>
<tr>
<td class="parameter_name"><p>buffer</p></td>
<td class="parameter_description"><p>a <a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstBuffer.html"><span class="type">GstBuffer</span></a> to push</p></td>
<td class="parameter_annotations"> </td>
</tr>
</tbody>
</table></div>
</div>
<div class="refsect3">
<a name="id-1.2.7.6.7.31.7"></a><h4>Returns</h4>
<p> a <a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstBuffer.html"><span class="type">GstBuffer</span></a> or <a href="https://developer.gnome.org/glib/unstable/glib-Standard-Macros.html#NULL:CAPS"><code class="literal">NULL</code></a> if timed out.</p>
</div>
<p class="since">Since: <a class="link" href="ix03.html#api-index-1.6">1.6</a></p>
</div>
<hr>
<div class="refsect2">
<a name="gst-harness-buffers-received"></a><h3>gst_harness_buffers_received ()</h3>
<pre class="programlisting"><a href="https://developer.gnome.org/glib/unstable/glib-Basic-Types.html#guint"><span class="returnvalue">guint</span></a>
gst_harness_buffers_received (<em class="parameter"><code><a class="link" href="gstreamer-libs-GstHarness.html#GstHarness" title="struct GstHarness"><span class="type">GstHarness</span></a> *h</code></em>);</pre>
<p>The total number of <a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstBuffer.html"><span class="type">GstBuffers</span></a> that has arrived on the <a class="link" href="gstreamer-libs-GstHarness.html#GstHarness" title="struct GstHarness"><span class="type">GstHarness</span></a> sinkpad.
This number includes buffers that have been dropped as well as buffers
that have already been pulled out.</p>
<p>MT safe.</p>
<div class="refsect3">
<a name="id-1.2.7.6.7.32.6"></a><h4>Parameters</h4>
<div class="informaltable"><table width="100%" border="0">
<colgroup>
<col width="150px" class="parameters_name">
<col class="parameters_description">
<col width="200px" class="parameters_annotations">
</colgroup>
<tbody><tr>
<td class="parameter_name"><p>h</p></td>
<td class="parameter_description"><p>a <a class="link" href="gstreamer-libs-GstHarness.html#GstHarness" title="struct GstHarness"><span class="type">GstHarness</span></a></p></td>
<td class="parameter_annotations"> </td>
</tr></tbody>
</table></div>
</div>
<div class="refsect3">
<a name="id-1.2.7.6.7.32.7"></a><h4>Returns</h4>
<p> a <a href="https://developer.gnome.org/glib/unstable/glib-Basic-Types.html#guint"><span class="type">guint</span></a> number of buffers received</p>
</div>
<p class="since">Since: <a class="link" href="ix03.html#api-index-1.6">1.6</a></p>
</div>
<hr>
<div class="refsect2">
<a name="gst-harness-buffers-in-queue"></a><h3>gst_harness_buffers_in_queue ()</h3>
<pre class="programlisting"><a href="https://developer.gnome.org/glib/unstable/glib-Basic-Types.html#guint"><span class="returnvalue">guint</span></a>
gst_harness_buffers_in_queue (<em class="parameter"><code><a class="link" href="gstreamer-libs-GstHarness.html#GstHarness" title="struct GstHarness"><span class="type">GstHarness</span></a> *h</code></em>);</pre>
<p>The number of <a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstBuffer.html"><span class="type">GstBuffers</span></a> currently in the <a class="link" href="gstreamer-libs-GstHarness.html#GstHarness" title="struct GstHarness"><span class="type">GstHarness</span></a> sinkpad <a href="https://developer.gnome.org/glib/unstable/glib-Asynchronous-Queues.html#GAsyncQueue"><span class="type">GAsyncQueue</span></a></p>
<p>MT safe.</p>
<div class="refsect3">
<a name="id-1.2.7.6.7.33.6"></a><h4>Parameters</h4>
<div class="informaltable"><table width="100%" border="0">
<colgroup>
<col width="150px" class="parameters_name">
<col class="parameters_description">
<col width="200px" class="parameters_annotations">
</colgroup>
<tbody><tr>
<td class="parameter_name"><p>h</p></td>
<td class="parameter_description"><p>a <a class="link" href="gstreamer-libs-GstHarness.html#GstHarness" title="struct GstHarness"><span class="type">GstHarness</span></a></p></td>
<td class="parameter_annotations"> </td>
</tr></tbody>
</table></div>
</div>
<div class="refsect3">
<a name="id-1.2.7.6.7.33.7"></a><h4>Returns</h4>
<p> a <a href="https://developer.gnome.org/glib/unstable/glib-Basic-Types.html#guint"><span class="type">guint</span></a> number of buffers in the queue</p>
</div>
<p class="since">Since: <a class="link" href="ix03.html#api-index-1.6">1.6</a></p>
</div>
<hr>
<div class="refsect2">
<a name="gst-harness-set-drop-buffers"></a><h3>gst_harness_set_drop_buffers ()</h3>
<pre class="programlisting"><span class="returnvalue">void</span>
gst_harness_set_drop_buffers (<em class="parameter"><code><a class="link" href="gstreamer-libs-GstHarness.html#GstHarness" title="struct GstHarness"><span class="type">GstHarness</span></a> *h</code></em>,
<em class="parameter"><code><a href="https://developer.gnome.org/glib/unstable/glib-Basic-Types.html#gboolean"><span class="type">gboolean</span></a> drop_buffers</code></em>);</pre>
<p>When set to <a href="https://developer.gnome.org/glib/unstable/glib-Standard-Macros.html#TRUE:CAPS"><code class="literal">TRUE</code></a>, instead of placing the buffers arriving from the harnessed
<a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstElement.html"><span class="type">GstElement</span></a> inside the sinkpads <a href="https://developer.gnome.org/glib/unstable/glib-Asynchronous-Queues.html#GAsyncQueue"><span class="type">GAsyncQueue</span></a>, they are instead unreffed.</p>
<p>MT safe.</p>
<div class="refsect3">
<a name="id-1.2.7.6.7.34.6"></a><h4>Parameters</h4>
<div class="informaltable"><table width="100%" border="0">
<colgroup>
<col width="150px" class="parameters_name">
<col class="parameters_description">
<col width="200px" class="parameters_annotations">
</colgroup>
<tbody>
<tr>
<td class="parameter_name"><p>h</p></td>
<td class="parameter_description"><p>a <a class="link" href="gstreamer-libs-GstHarness.html#GstHarness" title="struct GstHarness"><span class="type">GstHarness</span></a></p></td>
<td class="parameter_annotations"> </td>
</tr>
<tr>
<td class="parameter_name"><p>drop_buffers</p></td>
<td class="parameter_description"><p>a <a href="https://developer.gnome.org/glib/unstable/glib-Basic-Types.html#gboolean"><span class="type">gboolean</span></a> specifying to drop outgoing buffers or not</p></td>
<td class="parameter_annotations"> </td>
</tr>
</tbody>
</table></div>
</div>
<p class="since">Since: <a class="link" href="ix03.html#api-index-1.6">1.6</a></p>
</div>
<hr>
<div class="refsect2">
<a name="gst-harness-dump-to-file"></a><h3>gst_harness_dump_to_file ()</h3>
<pre class="programlisting"><span class="returnvalue">void</span>
gst_harness_dump_to_file (<em class="parameter"><code><a class="link" href="gstreamer-libs-GstHarness.html#GstHarness" title="struct GstHarness"><span class="type">GstHarness</span></a> *h</code></em>,
<em class="parameter"><code>const <a href="https://developer.gnome.org/glib/unstable/glib-Basic-Types.html#gchar"><span class="type">gchar</span></a> *filename</code></em>);</pre>
<p>Allows you to dump the <a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstBuffer.html"><span class="type">GstBuffers</span></a> the <a class="link" href="gstreamer-libs-GstHarness.html#GstHarness" title="struct GstHarness"><span class="type">GstHarness</span></a> sinkpad <a href="https://developer.gnome.org/glib/unstable/glib-Asynchronous-Queues.html#GAsyncQueue"><span class="type">GAsyncQueue</span></a>
to a file.</p>
<p>MT safe.</p>
<div class="refsect3">
<a name="id-1.2.7.6.7.35.6"></a><h4>Parameters</h4>
<div class="informaltable"><table width="100%" border="0">
<colgroup>
<col width="150px" class="parameters_name">
<col class="parameters_description">
<col width="200px" class="parameters_annotations">
</colgroup>
<tbody>
<tr>
<td class="parameter_name"><p>h</p></td>
<td class="parameter_description"><p>a <a class="link" href="gstreamer-libs-GstHarness.html#GstHarness" title="struct GstHarness"><span class="type">GstHarness</span></a></p></td>
<td class="parameter_annotations"> </td>
</tr>
<tr>
<td class="parameter_name"><p>filename</p></td>
<td class="parameter_description"><p>a <a href="https://developer.gnome.org/glib/unstable/glib-Basic-Types.html#gchar"><span class="type">gchar</span></a> with a the name of a file</p></td>
<td class="parameter_annotations"> </td>
</tr>
</tbody>
</table></div>
</div>
<p class="since">Since: <a class="link" href="ix03.html#api-index-1.6">1.6</a></p>
</div>
<hr>
<div class="refsect2">
<a name="gst-harness-get-last-pushed-timestamp"></a><h3>gst_harness_get_last_pushed_timestamp ()</h3>
<pre class="programlisting"><a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstClock.html#GstClockTime"><span class="returnvalue">GstClockTime</span></a>
gst_harness_get_last_pushed_timestamp (<em class="parameter"><code><a class="link" href="gstreamer-libs-GstHarness.html#GstHarness" title="struct GstHarness"><span class="type">GstHarness</span></a> *h</code></em>);</pre>
<p>Get the timestamp of the last <a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstBuffer.html"><span class="type">GstBuffer</span></a> pushed on the <a class="link" href="gstreamer-libs-GstHarness.html#GstHarness" title="struct GstHarness"><span class="type">GstHarness</span></a> srcpad,
typically with gst_harness_push or gst_harness_push_from_src.</p>
<p>MT safe.</p>
<div class="refsect3">
<a name="id-1.2.7.6.7.36.6"></a><h4>Parameters</h4>
<div class="informaltable"><table width="100%" border="0">
<colgroup>
<col width="150px" class="parameters_name">
<col class="parameters_description">
<col width="200px" class="parameters_annotations">
</colgroup>
<tbody><tr>
<td class="parameter_name"><p>h</p></td>
<td class="parameter_description"><p>a <a class="link" href="gstreamer-libs-GstHarness.html#GstHarness" title="struct GstHarness"><span class="type">GstHarness</span></a></p></td>
<td class="parameter_annotations"> </td>
</tr></tbody>
</table></div>
</div>
<div class="refsect3">
<a name="id-1.2.7.6.7.36.7"></a><h4>Returns</h4>
<p> a <a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstClock.html#GstClockTime"><span class="type">GstClockTime</span></a> with the timestamp or <a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstClock.html#GST-CLOCK-TIME-NONE:CAPS"><code class="literal">GST_CLOCK_TIME_NONE</code></a> if no
<a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstBuffer.html"><span class="type">GstBuffer</span></a> has been pushed on the <a class="link" href="gstreamer-libs-GstHarness.html#GstHarness" title="struct GstHarness"><span class="type">GstHarness</span></a> srcpad</p>
</div>
<p class="since">Since: <a class="link" href="ix03.html#api-index-1.6">1.6</a></p>
</div>
<hr>
<div class="refsect2">
<a name="gst-harness-push-event"></a><h3>gst_harness_push_event ()</h3>
<pre class="programlisting"><a href="https://developer.gnome.org/glib/unstable/glib-Basic-Types.html#gboolean"><span class="returnvalue">gboolean</span></a>
gst_harness_push_event (<em class="parameter"><code><a class="link" href="gstreamer-libs-GstHarness.html#GstHarness" title="struct GstHarness"><span class="type">GstHarness</span></a> *h</code></em>,
<em class="parameter"><code><a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstEvent.html"><span class="type">GstEvent</span></a> *event</code></em>);</pre>
<p>Pushes an <a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstEvent.html"><span class="type">GstEvent</span></a> on the <a class="link" href="gstreamer-libs-GstHarness.html#GstHarness" title="struct GstHarness"><span class="type">GstHarness</span></a> srcpad.</p>
<p>MT safe.</p>
<div class="refsect3">
<a name="id-1.2.7.6.7.37.6"></a><h4>Parameters</h4>
<div class="informaltable"><table width="100%" border="0">
<colgroup>
<col width="150px" class="parameters_name">
<col class="parameters_description">
<col width="200px" class="parameters_annotations">
</colgroup>
<tbody>
<tr>
<td class="parameter_name"><p>h</p></td>
<td class="parameter_description"><p>a <a class="link" href="gstreamer-libs-GstHarness.html#GstHarness" title="struct GstHarness"><span class="type">GstHarness</span></a></p></td>
<td class="parameter_annotations"> </td>
</tr>
<tr>
<td class="parameter_name"><p>event</p></td>
<td class="parameter_description"><p>a <a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstEvent.html"><span class="type">GstEvent</span></a> to push</p></td>
<td class="parameter_annotations"> </td>
</tr>
</tbody>
</table></div>
</div>
<div class="refsect3">
<a name="id-1.2.7.6.7.37.7"></a><h4>Returns</h4>
<p> a <a href="https://developer.gnome.org/glib/unstable/glib-Basic-Types.html#gboolean"><span class="type">gboolean</span></a> with the result from the push</p>
</div>
<p class="since">Since: <a class="link" href="ix03.html#api-index-1.6">1.6</a></p>
</div>
<hr>
<div class="refsect2">
<a name="gst-harness-pull-event"></a><h3>gst_harness_pull_event ()</h3>
<pre class="programlisting"><a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstEvent.html"><span class="returnvalue">GstEvent</span></a> *
gst_harness_pull_event (<em class="parameter"><code><a class="link" href="gstreamer-libs-GstHarness.html#GstHarness" title="struct GstHarness"><span class="type">GstHarness</span></a> *h</code></em>);</pre>
<p>Pulls an <a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstEvent.html"><span class="type">GstEvent</span></a> from the <a href="https://developer.gnome.org/glib/unstable/glib-Asynchronous-Queues.html#GAsyncQueue"><span class="type">GAsyncQueue</span></a> on the <a class="link" href="gstreamer-libs-GstHarness.html#GstHarness" title="struct GstHarness"><span class="type">GstHarness</span></a> sinkpad.
Timeouts after 60 seconds similar to gst_harness_pull.</p>
<p>MT safe.</p>
<div class="refsect3">
<a name="id-1.2.7.6.7.38.6"></a><h4>Parameters</h4>
<div class="informaltable"><table width="100%" border="0">
<colgroup>
<col width="150px" class="parameters_name">
<col class="parameters_description">
<col width="200px" class="parameters_annotations">
</colgroup>
<tbody><tr>
<td class="parameter_name"><p>h</p></td>
<td class="parameter_description"><p>a <a class="link" href="gstreamer-libs-GstHarness.html#GstHarness" title="struct GstHarness"><span class="type">GstHarness</span></a></p></td>
<td class="parameter_annotations"> </td>
</tr></tbody>
</table></div>
</div>
<div class="refsect3">
<a name="id-1.2.7.6.7.38.7"></a><h4>Returns</h4>
<p> a <a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstEvent.html"><span class="type">GstEvent</span></a> or <a href="https://developer.gnome.org/glib/unstable/glib-Standard-Macros.html#NULL:CAPS"><code class="literal">NULL</code></a> if timed out.</p>
</div>
<p class="since">Since: <a class="link" href="ix03.html#api-index-1.6">1.6</a></p>
</div>
<hr>
<div class="refsect2">
<a name="gst-harness-try-pull-event"></a><h3>gst_harness_try_pull_event ()</h3>
<pre class="programlisting"><a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstEvent.html"><span class="returnvalue">GstEvent</span></a> *
gst_harness_try_pull_event (<em class="parameter"><code><a class="link" href="gstreamer-libs-GstHarness.html#GstHarness" title="struct GstHarness"><span class="type">GstHarness</span></a> *h</code></em>);</pre>
<p>Pulls an <a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstEvent.html"><span class="type">GstEvent</span></a> from the <a href="https://developer.gnome.org/glib/unstable/glib-Asynchronous-Queues.html#GAsyncQueue"><span class="type">GAsyncQueue</span></a> on the <a class="link" href="gstreamer-libs-GstHarness.html#GstHarness" title="struct GstHarness"><span class="type">GstHarness</span></a> sinkpad.
See gst_harness_try_pull for details.</p>
<p>MT safe.</p>
<div class="refsect3">
<a name="id-1.2.7.6.7.39.6"></a><h4>Parameters</h4>
<div class="informaltable"><table width="100%" border="0">
<colgroup>
<col width="150px" class="parameters_name">
<col class="parameters_description">
<col width="200px" class="parameters_annotations">
</colgroup>
<tbody><tr>
<td class="parameter_name"><p>h</p></td>
<td class="parameter_description"><p>a <a class="link" href="gstreamer-libs-GstHarness.html#GstHarness" title="struct GstHarness"><span class="type">GstHarness</span></a></p></td>
<td class="parameter_annotations"> </td>
</tr></tbody>
</table></div>
</div>
<div class="refsect3">
<a name="id-1.2.7.6.7.39.7"></a><h4>Returns</h4>
<p> a <a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstEvent.html"><span class="type">GstEvent</span></a> or <a href="https://developer.gnome.org/glib/unstable/glib-Standard-Macros.html#NULL:CAPS"><code class="literal">NULL</code></a> if no buffers are present in the <a href="https://developer.gnome.org/glib/unstable/glib-Asynchronous-Queues.html#GAsyncQueue"><span class="type">GAsyncQueue</span></a></p>
</div>
<p class="since">Since: <a class="link" href="ix03.html#api-index-1.6">1.6</a></p>
</div>
<hr>
<div class="refsect2">
<a name="gst-harness-events-received"></a><h3>gst_harness_events_received ()</h3>
<pre class="programlisting"><a href="https://developer.gnome.org/glib/unstable/glib-Basic-Types.html#guint"><span class="returnvalue">guint</span></a>
gst_harness_events_received (<em class="parameter"><code><a class="link" href="gstreamer-libs-GstHarness.html#GstHarness" title="struct GstHarness"><span class="type">GstHarness</span></a> *h</code></em>);</pre>
<p>The total number of <a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstEvent.html"><span class="type">GstEvents</span></a> that has arrived on the <a class="link" href="gstreamer-libs-GstHarness.html#GstHarness" title="struct GstHarness"><span class="type">GstHarness</span></a> sinkpad
This number includes events handled by the harness as well as events
that have already been pulled out.</p>
<p>MT safe.</p>
<div class="refsect3">
<a name="id-1.2.7.6.7.40.6"></a><h4>Parameters</h4>
<div class="informaltable"><table width="100%" border="0">
<colgroup>
<col width="150px" class="parameters_name">
<col class="parameters_description">
<col width="200px" class="parameters_annotations">
</colgroup>
<tbody><tr>
<td class="parameter_name"><p>h</p></td>
<td class="parameter_description"><p>a <a class="link" href="gstreamer-libs-GstHarness.html#GstHarness" title="struct GstHarness"><span class="type">GstHarness</span></a></p></td>
<td class="parameter_annotations"> </td>
</tr></tbody>
</table></div>
</div>
<div class="refsect3">
<a name="id-1.2.7.6.7.40.7"></a><h4>Returns</h4>
<p> a <a href="https://developer.gnome.org/glib/unstable/glib-Basic-Types.html#guint"><span class="type">guint</span></a> number of events received</p>
</div>
<p class="since">Since: <a class="link" href="ix03.html#api-index-1.6">1.6</a></p>
</div>
<hr>
<div class="refsect2">
<a name="gst-harness-events-in-queue"></a><h3>gst_harness_events_in_queue ()</h3>
<pre class="programlisting"><a href="https://developer.gnome.org/glib/unstable/glib-Basic-Types.html#guint"><span class="returnvalue">guint</span></a>
gst_harness_events_in_queue (<em class="parameter"><code><a class="link" href="gstreamer-libs-GstHarness.html#GstHarness" title="struct GstHarness"><span class="type">GstHarness</span></a> *h</code></em>);</pre>
<p>The number of <a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstEvent.html"><span class="type">GstEvents</span></a> currently in the <a class="link" href="gstreamer-libs-GstHarness.html#GstHarness" title="struct GstHarness"><span class="type">GstHarness</span></a> sinkpad <a href="https://developer.gnome.org/glib/unstable/glib-Asynchronous-Queues.html#GAsyncQueue"><span class="type">GAsyncQueue</span></a></p>
<p>MT safe.</p>
<div class="refsect3">
<a name="id-1.2.7.6.7.41.6"></a><h4>Parameters</h4>
<div class="informaltable"><table width="100%" border="0">
<colgroup>
<col width="150px" class="parameters_name">
<col class="parameters_description">
<col width="200px" class="parameters_annotations">
</colgroup>
<tbody><tr>
<td class="parameter_name"><p>h</p></td>
<td class="parameter_description"><p>a <a class="link" href="gstreamer-libs-GstHarness.html#GstHarness" title="struct GstHarness"><span class="type">GstHarness</span></a></p></td>
<td class="parameter_annotations"> </td>
</tr></tbody>
</table></div>
</div>
<div class="refsect3">
<a name="id-1.2.7.6.7.41.7"></a><h4>Returns</h4>
<p> a <a href="https://developer.gnome.org/glib/unstable/glib-Basic-Types.html#guint"><span class="type">guint</span></a> number of events in the queue</p>
</div>
<p class="since">Since: <a class="link" href="ix03.html#api-index-1.6">1.6</a></p>
</div>
<hr>
<div class="refsect2">
<a name="gst-harness-push-upstream-event"></a><h3>gst_harness_push_upstream_event ()</h3>
<pre class="programlisting"><a href="https://developer.gnome.org/glib/unstable/glib-Basic-Types.html#gboolean"><span class="returnvalue">gboolean</span></a>
gst_harness_push_upstream_event (<em class="parameter"><code><a class="link" href="gstreamer-libs-GstHarness.html#GstHarness" title="struct GstHarness"><span class="type">GstHarness</span></a> *h</code></em>,
<em class="parameter"><code><a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstEvent.html"><span class="type">GstEvent</span></a> *event</code></em>);</pre>
<p>Pushes an <a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstEvent.html"><span class="type">GstEvent</span></a> on the <a class="link" href="gstreamer-libs-GstHarness.html#GstHarness" title="struct GstHarness"><span class="type">GstHarness</span></a> sinkpad.</p>
<p>MT safe.</p>
<div class="refsect3">
<a name="id-1.2.7.6.7.42.6"></a><h4>Parameters</h4>
<div class="informaltable"><table width="100%" border="0">
<colgroup>
<col width="150px" class="parameters_name">
<col class="parameters_description">
<col width="200px" class="parameters_annotations">
</colgroup>
<tbody>
<tr>
<td class="parameter_name"><p>h</p></td>
<td class="parameter_description"><p>a <a class="link" href="gstreamer-libs-GstHarness.html#GstHarness" title="struct GstHarness"><span class="type">GstHarness</span></a></p></td>
<td class="parameter_annotations"> </td>
</tr>
<tr>
<td class="parameter_name"><p>event</p></td>
<td class="parameter_description"><p>a <a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstEvent.html"><span class="type">GstEvent</span></a> to push</p></td>
<td class="parameter_annotations"> </td>
</tr>
</tbody>
</table></div>
</div>
<div class="refsect3">
<a name="id-1.2.7.6.7.42.7"></a><h4>Returns</h4>
<p> a <a href="https://developer.gnome.org/glib/unstable/glib-Basic-Types.html#gboolean"><span class="type">gboolean</span></a> with the result from the push</p>
</div>
<p class="since">Since: <a class="link" href="ix03.html#api-index-1.6">1.6</a></p>
</div>
<hr>
<div class="refsect2">
<a name="gst-harness-pull-upstream-event"></a><h3>gst_harness_pull_upstream_event ()</h3>
<pre class="programlisting"><a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstEvent.html"><span class="returnvalue">GstEvent</span></a> *
gst_harness_pull_upstream_event (<em class="parameter"><code><a class="link" href="gstreamer-libs-GstHarness.html#GstHarness" title="struct GstHarness"><span class="type">GstHarness</span></a> *h</code></em>);</pre>
<p>Pulls an <a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstEvent.html"><span class="type">GstEvent</span></a> from the <a href="https://developer.gnome.org/glib/unstable/glib-Asynchronous-Queues.html#GAsyncQueue"><span class="type">GAsyncQueue</span></a> on the <a class="link" href="gstreamer-libs-GstHarness.html#GstHarness" title="struct GstHarness"><span class="type">GstHarness</span></a> srcpad.
Timeouts after 60 seconds similar to gst_harness_pull.</p>
<p>MT safe.</p>
<div class="refsect3">
<a name="id-1.2.7.6.7.43.6"></a><h4>Parameters</h4>
<div class="informaltable"><table width="100%" border="0">
<colgroup>
<col width="150px" class="parameters_name">
<col class="parameters_description">
<col width="200px" class="parameters_annotations">
</colgroup>
<tbody><tr>
<td class="parameter_name"><p>h</p></td>
<td class="parameter_description"><p>a <a class="link" href="gstreamer-libs-GstHarness.html#GstHarness" title="struct GstHarness"><span class="type">GstHarness</span></a></p></td>
<td class="parameter_annotations"> </td>
</tr></tbody>
</table></div>
</div>
<div class="refsect3">
<a name="id-1.2.7.6.7.43.7"></a><h4>Returns</h4>
<p> a <a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstEvent.html"><span class="type">GstEvent</span></a> or <a href="https://developer.gnome.org/glib/unstable/glib-Standard-Macros.html#NULL:CAPS"><code class="literal">NULL</code></a> if timed out.</p>
</div>
<p class="since">Since: <a class="link" href="ix03.html#api-index-1.6">1.6</a></p>
</div>
<hr>
<div class="refsect2">
<a name="gst-harness-try-pull-upstream-event"></a><h3>gst_harness_try_pull_upstream_event ()</h3>
<pre class="programlisting"><a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstEvent.html"><span class="returnvalue">GstEvent</span></a> *
gst_harness_try_pull_upstream_event (<em class="parameter"><code><a class="link" href="gstreamer-libs-GstHarness.html#GstHarness" title="struct GstHarness"><span class="type">GstHarness</span></a> *h</code></em>);</pre>
<p>Pulls an <a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstEvent.html"><span class="type">GstEvent</span></a> from the <a href="https://developer.gnome.org/glib/unstable/glib-Asynchronous-Queues.html#GAsyncQueue"><span class="type">GAsyncQueue</span></a> on the <a class="link" href="gstreamer-libs-GstHarness.html#GstHarness" title="struct GstHarness"><span class="type">GstHarness</span></a> srcpad.
See gst_harness_try_pull for details.</p>
<p>MT safe.</p>
<div class="refsect3">
<a name="id-1.2.7.6.7.44.6"></a><h4>Parameters</h4>
<div class="informaltable"><table width="100%" border="0">
<colgroup>
<col width="150px" class="parameters_name">
<col class="parameters_description">
<col width="200px" class="parameters_annotations">
</colgroup>
<tbody><tr>
<td class="parameter_name"><p>h</p></td>
<td class="parameter_description"><p>a <a class="link" href="gstreamer-libs-GstHarness.html#GstHarness" title="struct GstHarness"><span class="type">GstHarness</span></a></p></td>
<td class="parameter_annotations"> </td>
</tr></tbody>
</table></div>
</div>
<div class="refsect3">
<a name="id-1.2.7.6.7.44.7"></a><h4>Returns</h4>
<p> a <a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstEvent.html"><span class="type">GstEvent</span></a> or <a href="https://developer.gnome.org/glib/unstable/glib-Standard-Macros.html#NULL:CAPS"><code class="literal">NULL</code></a> if no buffers are present in the <a href="https://developer.gnome.org/glib/unstable/glib-Asynchronous-Queues.html#GAsyncQueue"><span class="type">GAsyncQueue</span></a></p>
</div>
<p class="since">Since: <a class="link" href="ix03.html#api-index-1.6">1.6</a></p>
</div>
<hr>
<div class="refsect2">
<a name="gst-harness-upstream-events-received"></a><h3>gst_harness_upstream_events_received ()</h3>
<pre class="programlisting"><a href="https://developer.gnome.org/glib/unstable/glib-Basic-Types.html#guint"><span class="returnvalue">guint</span></a>
gst_harness_upstream_events_received (<em class="parameter"><code><a class="link" href="gstreamer-libs-GstHarness.html#GstHarness" title="struct GstHarness"><span class="type">GstHarness</span></a> *h</code></em>);</pre>
<p>The total number of <a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstEvent.html"><span class="type">GstEvents</span></a> that has arrived on the <a class="link" href="gstreamer-libs-GstHarness.html#GstHarness" title="struct GstHarness"><span class="type">GstHarness</span></a> srcpad
This number includes events handled by the harness as well as events
that have already been pulled out.</p>
<p>MT safe.</p>
<div class="refsect3">
<a name="id-1.2.7.6.7.45.6"></a><h4>Parameters</h4>
<div class="informaltable"><table width="100%" border="0">
<colgroup>
<col width="150px" class="parameters_name">
<col class="parameters_description">
<col width="200px" class="parameters_annotations">
</colgroup>
<tbody><tr>
<td class="parameter_name"><p>h</p></td>
<td class="parameter_description"><p>a <a class="link" href="gstreamer-libs-GstHarness.html#GstHarness" title="struct GstHarness"><span class="type">GstHarness</span></a></p></td>
<td class="parameter_annotations"> </td>
</tr></tbody>
</table></div>
</div>
<div class="refsect3">
<a name="id-1.2.7.6.7.45.7"></a><h4>Returns</h4>
<p> a <a href="https://developer.gnome.org/glib/unstable/glib-Basic-Types.html#guint"><span class="type">guint</span></a> number of events received</p>
</div>
<p class="since">Since: <a class="link" href="ix03.html#api-index-1.6">1.6</a></p>
</div>
<hr>
<div class="refsect2">
<a name="gst-harness-upstream-events-in-queue"></a><h3>gst_harness_upstream_events_in_queue ()</h3>
<pre class="programlisting"><a href="https://developer.gnome.org/glib/unstable/glib-Basic-Types.html#guint"><span class="returnvalue">guint</span></a>
gst_harness_upstream_events_in_queue (<em class="parameter"><code><a class="link" href="gstreamer-libs-GstHarness.html#GstHarness" title="struct GstHarness"><span class="type">GstHarness</span></a> *h</code></em>);</pre>
<p>The number of <a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstEvent.html"><span class="type">GstEvents</span></a> currently in the <a class="link" href="gstreamer-libs-GstHarness.html#GstHarness" title="struct GstHarness"><span class="type">GstHarness</span></a> srcpad <a href="https://developer.gnome.org/glib/unstable/glib-Asynchronous-Queues.html#GAsyncQueue"><span class="type">GAsyncQueue</span></a></p>
<p>MT safe.</p>
<div class="refsect3">
<a name="id-1.2.7.6.7.46.6"></a><h4>Parameters</h4>
<div class="informaltable"><table width="100%" border="0">
<colgroup>
<col width="150px" class="parameters_name">
<col class="parameters_description">
<col width="200px" class="parameters_annotations">
</colgroup>
<tbody><tr>
<td class="parameter_name"><p>h</p></td>
<td class="parameter_description"><p>a <a class="link" href="gstreamer-libs-GstHarness.html#GstHarness" title="struct GstHarness"><span class="type">GstHarness</span></a></p></td>
<td class="parameter_annotations"> </td>
</tr></tbody>
</table></div>
</div>
<div class="refsect3">
<a name="id-1.2.7.6.7.46.7"></a><h4>Returns</h4>
<p> a <a href="https://developer.gnome.org/glib/unstable/glib-Basic-Types.html#guint"><span class="type">guint</span></a> number of events in the queue</p>
</div>
<p class="since">Since: <a class="link" href="ix03.html#api-index-1.6">1.6</a></p>
</div>
<hr>
<div class="refsect2">
<a name="gst-harness-query-latency"></a><h3>gst_harness_query_latency ()</h3>
<pre class="programlisting"><a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstClock.html#GstClockTime"><span class="returnvalue">GstClockTime</span></a>
gst_harness_query_latency (<em class="parameter"><code><a class="link" href="gstreamer-libs-GstHarness.html#GstHarness" title="struct GstHarness"><span class="type">GstHarness</span></a> *h</code></em>);</pre>
<p>Get the min latency reported by any harnessed <a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstElement.html"><span class="type">GstElement</span></a>.</p>
<p>MT safe.</p>
<div class="refsect3">
<a name="id-1.2.7.6.7.47.6"></a><h4>Parameters</h4>
<div class="informaltable"><table width="100%" border="0">
<colgroup>
<col width="150px" class="parameters_name">
<col class="parameters_description">
<col width="200px" class="parameters_annotations">
</colgroup>
<tbody><tr>
<td class="parameter_name"><p>h</p></td>
<td class="parameter_description"><p>a <a class="link" href="gstreamer-libs-GstHarness.html#GstHarness" title="struct GstHarness"><span class="type">GstHarness</span></a></p></td>
<td class="parameter_annotations"> </td>
</tr></tbody>
</table></div>
</div>
<div class="refsect3">
<a name="id-1.2.7.6.7.47.7"></a><h4>Returns</h4>
<p> a <a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstClock.html#GstClockTime"><span class="type">GstClockTime</span></a> with min latency</p>
</div>
<p class="since">Since: <a class="link" href="ix03.html#api-index-1.6">1.6</a></p>
</div>
<hr>
<div class="refsect2">
<a name="gst-harness-set-upstream-latency"></a><h3>gst_harness_set_upstream_latency ()</h3>
<pre class="programlisting"><span class="returnvalue">void</span>
gst_harness_set_upstream_latency (<em class="parameter"><code><a class="link" href="gstreamer-libs-GstHarness.html#GstHarness" title="struct GstHarness"><span class="type">GstHarness</span></a> *h</code></em>,
<em class="parameter"><code><a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstClock.html#GstClockTime"><span class="type">GstClockTime</span></a> latency</code></em>);</pre>
<p>Sets the min latency reported by <a class="link" href="gstreamer-libs-GstHarness.html#GstHarness" title="struct GstHarness"><span class="type">GstHarness</span></a> when receiving a latency-query</p>
<p>MT safe.</p>
<div class="refsect3">
<a name="id-1.2.7.6.7.48.6"></a><h4>Parameters</h4>
<div class="informaltable"><table width="100%" border="0">
<colgroup>
<col width="150px" class="parameters_name">
<col class="parameters_description">
<col width="200px" class="parameters_annotations">
</colgroup>
<tbody>
<tr>
<td class="parameter_name"><p>h</p></td>
<td class="parameter_description"><p>a <a class="link" href="gstreamer-libs-GstHarness.html#GstHarness" title="struct GstHarness"><span class="type">GstHarness</span></a></p></td>
<td class="parameter_annotations"> </td>
</tr>
<tr>
<td class="parameter_name"><p>latency</p></td>
<td class="parameter_description"><p>a <a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstClock.html#GstClockTime"><span class="type">GstClockTime</span></a> specifying the latency</p></td>
<td class="parameter_annotations"> </td>
</tr>
</tbody>
</table></div>
</div>
<div class="refsect3">
<a name="id-1.2.7.6.7.48.7"></a><h4>Returns</h4>
<p> a <a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstClock.html#GstClockTime"><span class="type">GstClockTime</span></a> with min latency</p>
</div>
<p class="since">Since: <a class="link" href="ix03.html#api-index-1.6">1.6</a></p>
</div>
<hr>
<div class="refsect2">
<a name="gst-harness-set-propose-allocator"></a><h3>gst_harness_set_propose_allocator ()</h3>
<pre class="programlisting"><span class="returnvalue">void</span>
gst_harness_set_propose_allocator (<em class="parameter"><code><a class="link" href="gstreamer-libs-GstHarness.html#GstHarness" title="struct GstHarness"><span class="type">GstHarness</span></a> *h</code></em>,
<em class="parameter"><code><a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstAllocator.html"><span class="type">GstAllocator</span></a> *allocator</code></em>,
<em class="parameter"><code>const <a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstAllocator.html#GstAllocationParams"><span class="type">GstAllocationParams</span></a> *params</code></em>);</pre>
<p>Sets the <em class="parameter"><code>allocator</code></em>
and <em class="parameter"><code>params</code></em>
to propose when receiving an allocation
query.</p>
<p>MT safe.</p>
<div class="refsect3">
<a name="id-1.2.7.6.7.49.6"></a><h4>Parameters</h4>
<div class="informaltable"><table width="100%" border="0">
<colgroup>
<col width="150px" class="parameters_name">
<col class="parameters_description">
<col width="200px" class="parameters_annotations">
</colgroup>
<tbody>
<tr>
<td class="parameter_name"><p>h</p></td>
<td class="parameter_description"><p>a <a class="link" href="gstreamer-libs-GstHarness.html#GstHarness" title="struct GstHarness"><span class="type">GstHarness</span></a></p></td>
<td class="parameter_annotations"> </td>
</tr>
<tr>
<td class="parameter_name"><p>allocator</p></td>
<td class="parameter_description"><p> a <a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstAllocator.html"><span class="type">GstAllocator</span></a>. </p></td>
<td class="parameter_annotations"><span class="annotation">[<acronym title="NULL is OK, both for passing and for returning."><span class="acronym">allow-none</span></acronym>][<acronym title="Free data after the code is done."><span class="acronym">transfer full</span></acronym>]</span></td>
</tr>
<tr>
<td class="parameter_name"><p>params</p></td>
<td class="parameter_description"><p> a <a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstAllocator.html#GstAllocationParams"><span class="type">GstAllocationParams</span></a>. </p></td>
<td class="parameter_annotations"><span class="annotation">[<acronym title="NULL is OK, both for passing and for returning."><span class="acronym">allow-none</span></acronym>][<acronym title="Don't free data after the code is done."><span class="acronym">transfer none</span></acronym>]</span></td>
</tr>
</tbody>
</table></div>
</div>
<p class="since">Since: <a class="link" href="ix03.html#api-index-1.6">1.6</a></p>
</div>
<hr>
<div class="refsect2">
<a name="gst-harness-get-allocator"></a><h3>gst_harness_get_allocator ()</h3>
<pre class="programlisting"><span class="returnvalue">void</span>
gst_harness_get_allocator (<em class="parameter"><code><a class="link" href="gstreamer-libs-GstHarness.html#GstHarness" title="struct GstHarness"><span class="type">GstHarness</span></a> *h</code></em>,
<em class="parameter"><code><a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstAllocator.html"><span class="type">GstAllocator</span></a> **allocator</code></em>,
<em class="parameter"><code><a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstAllocator.html#GstAllocationParams"><span class="type">GstAllocationParams</span></a> *params</code></em>);</pre>
<p>Gets the <em class="parameter"><code>allocator</code></em>
and its <em class="parameter"><code>params</code></em>
that has been decided to use after an
allocation query.</p>
<p>MT safe.</p>
<div class="refsect3">
<a name="id-1.2.7.6.7.50.6"></a><h4>Parameters</h4>
<div class="informaltable"><table width="100%" border="0">
<colgroup>
<col width="150px" class="parameters_name">
<col class="parameters_description">
<col width="200px" class="parameters_annotations">
</colgroup>
<tbody>
<tr>
<td class="parameter_name"><p>h</p></td>
<td class="parameter_description"><p>a <a class="link" href="gstreamer-libs-GstHarness.html#GstHarness" title="struct GstHarness"><span class="type">GstHarness</span></a></p></td>
<td class="parameter_annotations"> </td>
</tr>
<tr>
<td class="parameter_name"><p>allocator</p></td>
<td class="parameter_description"><p> the <a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstAllocator.html"><span class="type">GstAllocator</span></a> used. </p></td>
<td class="parameter_annotations"><span class="annotation">[<acronym title="Parameter for returning results. Default is transfer full."><span class="acronym">out</span></acronym>][<acronym title="NULL is OK, both for passing and for returning."><span class="acronym">allow-none</span></acronym>][<acronym title="Don't free data after the code is done."><span class="acronym">transfer none</span></acronym>]</span></td>
</tr>
<tr>
<td class="parameter_name"><p>params</p></td>
<td class="parameter_description"><p> the <a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstAllocator.html#GstAllocationParams"><span class="type">GstAllocationParams</span></a> of
<em class="parameter"><code>allocator</code></em>
. </p></td>
<td class="parameter_annotations"><span class="annotation">[<acronym title="Parameter for returning results. Default is transfer full."><span class="acronym">out</span></acronym>][<acronym title="NULL is OK, both for passing and for returning."><span class="acronym">allow-none</span></acronym>][<acronym title="Free data after the code is done."><span class="acronym">transfer full</span></acronym>]</span></td>
</tr>
</tbody>
</table></div>
</div>
<p class="since">Since: <a class="link" href="ix03.html#api-index-1.6">1.6</a></p>
</div>
<hr>
<div class="refsect2">
<a name="gst-harness-add-src"></a><h3>gst_harness_add_src ()</h3>
<pre class="programlisting"><span class="returnvalue">void</span>
gst_harness_add_src (<em class="parameter"><code><a class="link" href="gstreamer-libs-GstHarness.html#GstHarness" title="struct GstHarness"><span class="type">GstHarness</span></a> *h</code></em>,
<em class="parameter"><code>const <a href="https://developer.gnome.org/glib/unstable/glib-Basic-Types.html#gchar"><span class="type">gchar</span></a> *src_element_name</code></em>,
<em class="parameter"><code><a href="https://developer.gnome.org/glib/unstable/glib-Basic-Types.html#gboolean"><span class="type">gboolean</span></a> has_clock_wait</code></em>);</pre>
<p>Similar to gst_harness_add_src_harness, this is a convenience to
directly create a src-harness using the <em class="parameter"><code>src_element_name</code></em>
name specified.</p>
<p>MT safe.</p>
<div class="refsect3">
<a name="id-1.2.7.6.7.51.6"></a><h4>Parameters</h4>
<div class="informaltable"><table width="100%" border="0">
<colgroup>
<col width="150px" class="parameters_name">
<col class="parameters_description">
<col width="200px" class="parameters_annotations">
</colgroup>
<tbody>
<tr>
<td class="parameter_name"><p>h</p></td>
<td class="parameter_description"><p>a <a class="link" href="gstreamer-libs-GstHarness.html#GstHarness" title="struct GstHarness"><span class="type">GstHarness</span></a></p></td>
<td class="parameter_annotations"> </td>
</tr>
<tr>
<td class="parameter_name"><p>src_element_name</p></td>
<td class="parameter_description"><p>a <a href="https://developer.gnome.org/glib/unstable/glib-Basic-Types.html#gchar"><span class="type">gchar</span></a> with the name of a <a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstElement.html"><span class="type">GstElement</span></a></p></td>
<td class="parameter_annotations"> </td>
</tr>
<tr>
<td class="parameter_name"><p>has_clock_wait</p></td>
<td class="parameter_description"><p>a <a href="https://developer.gnome.org/glib/unstable/glib-Basic-Types.html#gboolean"><span class="type">gboolean</span></a> specifying if the <a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstElement.html"><span class="type">GstElement</span></a> uses
gst_clock_wait_id internally.</p></td>
<td class="parameter_annotations"> </td>
</tr>
</tbody>
</table></div>
</div>
<p class="since">Since: <a class="link" href="ix03.html#api-index-1.6">1.6</a></p>
</div>
<hr>
<div class="refsect2">
<a name="gst-harness-add-src-harness"></a><h3>gst_harness_add_src_harness ()</h3>
<pre class="programlisting"><span class="returnvalue">void</span>
gst_harness_add_src_harness (<em class="parameter"><code><a class="link" href="gstreamer-libs-GstHarness.html#GstHarness" title="struct GstHarness"><span class="type">GstHarness</span></a> *h</code></em>,
<em class="parameter"><code><a class="link" href="gstreamer-libs-GstHarness.html#GstHarness" title="struct GstHarness"><span class="type">GstHarness</span></a> *src_harness</code></em>,
<em class="parameter"><code><a href="https://developer.gnome.org/glib/unstable/glib-Basic-Types.html#gboolean"><span class="type">gboolean</span></a> has_clock_wait</code></em>);</pre>
<p>A src-harness is a great way of providing the <a class="link" href="gstreamer-libs-GstHarness.html#GstHarness" title="struct GstHarness"><span class="type">GstHarness</span></a> with data.
By adding a src-type <a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstElement.html"><span class="type">GstElement</span></a>, it is then easy to use functions like
gst_harness_push_from_src or gst_harness_src_crank_and_push_many
to provide your harnessed element with input. The <em class="parameter"><code>has_clock_wait</code></em>
variable
is a greate way to control you src-element with, in that you can have it
produce a buffer for you by simply cranking the clock, and not have it
spin out of control producing buffers as fast as possible.</p>
<p>If a src-harness already exists it will be replaced.</p>
<p>MT safe.</p>
<div class="refsect3">
<a name="id-1.2.7.6.7.52.7"></a><h4>Parameters</h4>
<div class="informaltable"><table width="100%" border="0">
<colgroup>
<col width="150px" class="parameters_name">
<col class="parameters_description">
<col width="200px" class="parameters_annotations">
</colgroup>
<tbody>
<tr>
<td class="parameter_name"><p>h</p></td>
<td class="parameter_description"><p>a <a class="link" href="gstreamer-libs-GstHarness.html#GstHarness" title="struct GstHarness"><span class="type">GstHarness</span></a></p></td>
<td class="parameter_annotations"> </td>
</tr>
<tr>
<td class="parameter_name"><p>src_harness</p></td>
<td class="parameter_description"><p> a <a class="link" href="gstreamer-libs-GstHarness.html#GstHarness" title="struct GstHarness"><span class="type">GstHarness</span></a> to be added as a src-harness. </p></td>
<td class="parameter_annotations"><span class="annotation">[<acronym title="Free data after the code is done."><span class="acronym">transfer full</span></acronym>]</span></td>
</tr>
<tr>
<td class="parameter_name"><p>has_clock_wait</p></td>
<td class="parameter_description"><p>a <a href="https://developer.gnome.org/glib/unstable/glib-Basic-Types.html#gboolean"><span class="type">gboolean</span></a> specifying if the <a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstElement.html"><span class="type">GstElement</span></a> uses
gst_clock_wait_id internally.</p></td>
<td class="parameter_annotations"> </td>
</tr>
</tbody>
</table></div>
</div>
<p class="since">Since: <a class="link" href="ix03.html#api-index-1.6">1.6</a></p>
</div>
<hr>
<div class="refsect2">
<a name="gst-harness-add-src-parse"></a><h3>gst_harness_add_src_parse ()</h3>
<pre class="programlisting"><span class="returnvalue">void</span>
gst_harness_add_src_parse (<em class="parameter"><code><a class="link" href="gstreamer-libs-GstHarness.html#GstHarness" title="struct GstHarness"><span class="type">GstHarness</span></a> *h</code></em>,
<em class="parameter"><code>const <a href="https://developer.gnome.org/glib/unstable/glib-Basic-Types.html#gchar"><span class="type">gchar</span></a> *launchline</code></em>,
<em class="parameter"><code><a href="https://developer.gnome.org/glib/unstable/glib-Basic-Types.html#gboolean"><span class="type">gboolean</span></a> has_clock_wait</code></em>);</pre>
<p>Similar to gst_harness_add_src, this allows you to specify a launch-line,
which can be useful for both having more then one <a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstElement.html"><span class="type">GstElement</span></a> acting as your
src (Like a src producing raw buffers, and then an encoder, providing encoded
data), but also by allowing you to set properties like "is-live" directly on
the elements.</p>
<p>MT safe.</p>
<div class="refsect3">
<a name="id-1.2.7.6.7.53.6"></a><h4>Parameters</h4>
<div class="informaltable"><table width="100%" border="0">
<colgroup>
<col width="150px" class="parameters_name">
<col class="parameters_description">
<col width="200px" class="parameters_annotations">
</colgroup>
<tbody>
<tr>
<td class="parameter_name"><p>h</p></td>
<td class="parameter_description"><p>a <a class="link" href="gstreamer-libs-GstHarness.html#GstHarness" title="struct GstHarness"><span class="type">GstHarness</span></a></p></td>
<td class="parameter_annotations"> </td>
</tr>
<tr>
<td class="parameter_name"><p>launchline</p></td>
<td class="parameter_description"><p>a <a href="https://developer.gnome.org/glib/unstable/glib-Basic-Types.html#gchar"><span class="type">gchar</span></a> describing a gst-launch type line</p></td>
<td class="parameter_annotations"> </td>
</tr>
<tr>
<td class="parameter_name"><p>has_clock_wait</p></td>
<td class="parameter_description"><p>a <a href="https://developer.gnome.org/glib/unstable/glib-Basic-Types.html#gboolean"><span class="type">gboolean</span></a> specifying if the <a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstElement.html"><span class="type">GstElement</span></a> uses
gst_clock_wait_id internally.</p></td>
<td class="parameter_annotations"> </td>
</tr>
</tbody>
</table></div>
</div>
<p class="since">Since: <a class="link" href="ix03.html#api-index-1.6">1.6</a></p>
</div>
<hr>
<div class="refsect2">
<a name="gst-harness-push-from-src"></a><h3>gst_harness_push_from_src ()</h3>
<pre class="programlisting"><a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstPad.html#GstFlowReturn"><span class="returnvalue">GstFlowReturn</span></a>
gst_harness_push_from_src (<em class="parameter"><code><a class="link" href="gstreamer-libs-GstHarness.html#GstHarness" title="struct GstHarness"><span class="type">GstHarness</span></a> *h</code></em>);</pre>
<p>Transfer data from the src-<a class="link" href="gstreamer-libs-GstHarness.html#GstHarness" title="struct GstHarness"><span class="type">GstHarness</span></a> to the main-<a class="link" href="gstreamer-libs-GstHarness.html#GstHarness" title="struct GstHarness"><span class="type">GstHarness</span></a>. It consists
of 4 steps:
1: Make sure the src is started. (see: gst_harness_play)
2: Crank the clock (see: gst_harness_crank_single_clock_wait)
3: Pull a <a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstBuffer.html"><span class="type">GstBuffer</span></a> from the src-<a class="link" href="gstreamer-libs-GstHarness.html#GstHarness" title="struct GstHarness"><span class="type">GstHarness</span></a> (see: gst_harness_pull)
4: Push the same <a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstBuffer.html"><span class="type">GstBuffer</span></a> into the main-<a class="link" href="gstreamer-libs-GstHarness.html#GstHarness" title="struct GstHarness"><span class="type">GstHarness</span></a> (see: gst_harness_push)</p>
<p>MT safe.</p>
<div class="refsect3">
<a name="id-1.2.7.6.7.54.6"></a><h4>Parameters</h4>
<div class="informaltable"><table width="100%" border="0">
<colgroup>
<col width="150px" class="parameters_name">
<col class="parameters_description">
<col width="200px" class="parameters_annotations">
</colgroup>
<tbody><tr>
<td class="parameter_name"><p>h</p></td>
<td class="parameter_description"><p>a <a class="link" href="gstreamer-libs-GstHarness.html#GstHarness" title="struct GstHarness"><span class="type">GstHarness</span></a></p></td>
<td class="parameter_annotations"> </td>
</tr></tbody>
</table></div>
</div>
<div class="refsect3">
<a name="id-1.2.7.6.7.54.7"></a><h4>Returns</h4>
<p> a <a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstPad.html#GstFlowReturn"><span class="type">GstFlowReturn</span></a> with the result of the push</p>
</div>
<p class="since">Since: <a class="link" href="ix03.html#api-index-1.6">1.6</a></p>
</div>
<hr>
<div class="refsect2">
<a name="gst-harness-src-crank-and-push-many"></a><h3>gst_harness_src_crank_and_push_many ()</h3>
<pre class="programlisting"><a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstPad.html#GstFlowReturn"><span class="returnvalue">GstFlowReturn</span></a>
gst_harness_src_crank_and_push_many (<em class="parameter"><code><a class="link" href="gstreamer-libs-GstHarness.html#GstHarness" title="struct GstHarness"><span class="type">GstHarness</span></a> *h</code></em>,
<em class="parameter"><code><a href="https://developer.gnome.org/glib/unstable/glib-Basic-Types.html#gint"><span class="type">gint</span></a> cranks</code></em>,
<em class="parameter"><code><a href="https://developer.gnome.org/glib/unstable/glib-Basic-Types.html#gint"><span class="type">gint</span></a> pushes</code></em>);</pre>
<p>Transfer data from the src-<a class="link" href="gstreamer-libs-GstHarness.html#GstHarness" title="struct GstHarness"><span class="type">GstHarness</span></a> to the main-<a class="link" href="gstreamer-libs-GstHarness.html#GstHarness" title="struct GstHarness"><span class="type">GstHarness</span></a>. Similar to
gst_harness_push_from_src, this variant allows you to specify how many cranks
and how many pushes to perform. This can be useful for both moving a lot
of data at the same time, as well as cases when one crank does not equal one
buffer to push and v.v.</p>
<p>MT safe.</p>
<div class="refsect3">
<a name="id-1.2.7.6.7.55.6"></a><h4>Parameters</h4>
<div class="informaltable"><table width="100%" border="0">
<colgroup>
<col width="150px" class="parameters_name">
<col class="parameters_description">
<col width="200px" class="parameters_annotations">
</colgroup>
<tbody>
<tr>
<td class="parameter_name"><p>h</p></td>
<td class="parameter_description"><p>a <a class="link" href="gstreamer-libs-GstHarness.html#GstHarness" title="struct GstHarness"><span class="type">GstHarness</span></a></p></td>
<td class="parameter_annotations"> </td>
</tr>
<tr>
<td class="parameter_name"><p>cranks</p></td>
<td class="parameter_description"><p>a <a href="https://developer.gnome.org/glib/unstable/glib-Basic-Types.html#gint"><span class="type">gint</span></a> with the number of calls to gst_harness_crank_single_clock_wait</p></td>
<td class="parameter_annotations"> </td>
</tr>
<tr>
<td class="parameter_name"><p>pushes</p></td>
<td class="parameter_description"><p>a <a href="https://developer.gnome.org/glib/unstable/glib-Basic-Types.html#gint"><span class="type">gint</span></a> with the number of calls to gst_harness_push</p></td>
<td class="parameter_annotations"> </td>
</tr>
</tbody>
</table></div>
</div>
<div class="refsect3">
<a name="id-1.2.7.6.7.55.7"></a><h4>Returns</h4>
<p> a <a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstPad.html#GstFlowReturn"><span class="type">GstFlowReturn</span></a> with the result of the push</p>
</div>
<p class="since">Since: <a class="link" href="ix03.html#api-index-1.6">1.6</a></p>
</div>
<hr>
<div class="refsect2">
<a name="gst-harness-src-push-event"></a><h3>gst_harness_src_push_event ()</h3>
<pre class="programlisting"><a href="https://developer.gnome.org/glib/unstable/glib-Basic-Types.html#gboolean"><span class="returnvalue">gboolean</span></a>
gst_harness_src_push_event (<em class="parameter"><code><a class="link" href="gstreamer-libs-GstHarness.html#GstHarness" title="struct GstHarness"><span class="type">GstHarness</span></a> *h</code></em>);</pre>
<p>Similar to what gst_harness_src_push does with <a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstBuffer.html"><span class="type">GstBuffers</span></a>, this transfers
a <a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstEvent.html"><span class="type">GstEvent</span></a> from the src-<a class="link" href="gstreamer-libs-GstHarness.html#GstHarness" title="struct GstHarness"><span class="type">GstHarness</span></a> to the main-<a class="link" href="gstreamer-libs-GstHarness.html#GstHarness" title="struct GstHarness"><span class="type">GstHarness</span></a>. Note that
some <a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstEvent.html"><span class="type">GstEvents</span></a> are being transferred automagically. Look at sink_forward_pad
for details.</p>
<p>MT safe.</p>
<div class="refsect3">
<a name="id-1.2.7.6.7.56.6"></a><h4>Parameters</h4>
<div class="informaltable"><table width="100%" border="0">
<colgroup>
<col width="150px" class="parameters_name">
<col class="parameters_description">
<col width="200px" class="parameters_annotations">
</colgroup>
<tbody><tr>
<td class="parameter_name"><p>h</p></td>
<td class="parameter_description"><p>a <a class="link" href="gstreamer-libs-GstHarness.html#GstHarness" title="struct GstHarness"><span class="type">GstHarness</span></a></p></td>
<td class="parameter_annotations"> </td>
</tr></tbody>
</table></div>
</div>
<div class="refsect3">
<a name="id-1.2.7.6.7.56.7"></a><h4>Returns</h4>
<p> a <a href="https://developer.gnome.org/glib/unstable/glib-Basic-Types.html#gboolean"><span class="type">gboolean</span></a> with the result of the push</p>
</div>
<p class="since">Since: <a class="link" href="ix03.html#api-index-1.6">1.6</a></p>
</div>
<hr>
<div class="refsect2">
<a name="gst-harness-add-sink"></a><h3>gst_harness_add_sink ()</h3>
<pre class="programlisting"><span class="returnvalue">void</span>
gst_harness_add_sink (<em class="parameter"><code><a class="link" href="gstreamer-libs-GstHarness.html#GstHarness" title="struct GstHarness"><span class="type">GstHarness</span></a> *h</code></em>,
<em class="parameter"><code>const <a href="https://developer.gnome.org/glib/unstable/glib-Basic-Types.html#gchar"><span class="type">gchar</span></a> *sink_element_name</code></em>);</pre>
<p>Similar to gst_harness_add_sink_harness, this is a convenience to
directly create a sink-harness using the <em class="parameter"><code>sink_element_name</code></em>
name specified.</p>
<p>MT safe.</p>
<div class="refsect3">
<a name="id-1.2.7.6.7.57.6"></a><h4>Parameters</h4>
<div class="informaltable"><table width="100%" border="0">
<colgroup>
<col width="150px" class="parameters_name">
<col class="parameters_description">
<col width="200px" class="parameters_annotations">
</colgroup>
<tbody>
<tr>
<td class="parameter_name"><p>h</p></td>
<td class="parameter_description"><p>a <a class="link" href="gstreamer-libs-GstHarness.html#GstHarness" title="struct GstHarness"><span class="type">GstHarness</span></a></p></td>
<td class="parameter_annotations"> </td>
</tr>
<tr>
<td class="parameter_name"><p>sink_element_name</p></td>
<td class="parameter_description"><p>a <a href="https://developer.gnome.org/glib/unstable/glib-Basic-Types.html#gchar"><span class="type">gchar</span></a> with the name of a <a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstElement.html"><span class="type">GstElement</span></a></p></td>
<td class="parameter_annotations"> </td>
</tr>
</tbody>
</table></div>
</div>
<p class="since">Since: <a class="link" href="ix03.html#api-index-1.6">1.6</a></p>
</div>
<hr>
<div class="refsect2">
<a name="gst-harness-add-sink-harness"></a><h3>gst_harness_add_sink_harness ()</h3>
<pre class="programlisting"><span class="returnvalue">void</span>
gst_harness_add_sink_harness (<em class="parameter"><code><a class="link" href="gstreamer-libs-GstHarness.html#GstHarness" title="struct GstHarness"><span class="type">GstHarness</span></a> *h</code></em>,
<em class="parameter"><code><a class="link" href="gstreamer-libs-GstHarness.html#GstHarness" title="struct GstHarness"><span class="type">GstHarness</span></a> *sink_harness</code></em>);</pre>
<p>Similar to gst_harness_add_src, this allows you to send the data coming out
of your harnessed <a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstElement.html"><span class="type">GstElement</span></a> to a sink-element, allowing to test different
responses the element output might create in sink elements. An example might
be an existing sink providing some analytical data on the input it receives that
can be useful to your testing. If the goal is to test a sink-element itself,
this is better acheived using gst_harness_new directly on the sink.</p>
<p>If a sink-harness already exists it will be replaced.</p>
<p>MT safe.</p>
<div class="refsect3">
<a name="id-1.2.7.6.7.58.7"></a><h4>Parameters</h4>
<div class="informaltable"><table width="100%" border="0">
<colgroup>
<col width="150px" class="parameters_name">
<col class="parameters_description">
<col width="200px" class="parameters_annotations">
</colgroup>
<tbody>
<tr>
<td class="parameter_name"><p>h</p></td>
<td class="parameter_description"><p>a <a class="link" href="gstreamer-libs-GstHarness.html#GstHarness" title="struct GstHarness"><span class="type">GstHarness</span></a></p></td>
<td class="parameter_annotations"> </td>
</tr>
<tr>
<td class="parameter_name"><p>sink_harness</p></td>
<td class="parameter_description"><p> a <a class="link" href="gstreamer-libs-GstHarness.html#GstHarness" title="struct GstHarness"><span class="type">GstHarness</span></a> to be added as a sink-harness. </p></td>
<td class="parameter_annotations"><span class="annotation">[<acronym title="Free data after the code is done."><span class="acronym">transfer full</span></acronym>]</span></td>
</tr>
</tbody>
</table></div>
</div>
<p class="since">Since: <a class="link" href="ix03.html#api-index-1.6">1.6</a></p>
</div>
<hr>
<div class="refsect2">
<a name="gst-harness-add-sink-parse"></a><h3>gst_harness_add_sink_parse ()</h3>
<pre class="programlisting"><span class="returnvalue">void</span>
gst_harness_add_sink_parse (<em class="parameter"><code><a class="link" href="gstreamer-libs-GstHarness.html#GstHarness" title="struct GstHarness"><span class="type">GstHarness</span></a> *h</code></em>,
<em class="parameter"><code>const <a href="https://developer.gnome.org/glib/unstable/glib-Basic-Types.html#gchar"><span class="type">gchar</span></a> *launchline</code></em>);</pre>
<p>Similar to gst_harness_add_sink, this allows you to specify a launch-line
instead of just an element name. See gst_harness_add_src_parse for details.</p>
<p>MT safe.</p>
<div class="refsect3">
<a name="id-1.2.7.6.7.59.6"></a><h4>Parameters</h4>
<div class="informaltable"><table width="100%" border="0">
<colgroup>
<col width="150px" class="parameters_name">
<col class="parameters_description">
<col width="200px" class="parameters_annotations">
</colgroup>
<tbody>
<tr>
<td class="parameter_name"><p>h</p></td>
<td class="parameter_description"><p>a <a class="link" href="gstreamer-libs-GstHarness.html#GstHarness" title="struct GstHarness"><span class="type">GstHarness</span></a></p></td>
<td class="parameter_annotations"> </td>
</tr>
<tr>
<td class="parameter_name"><p>launchline</p></td>
<td class="parameter_description"><p>a <a href="https://developer.gnome.org/glib/unstable/glib-Basic-Types.html#gchar"><span class="type">gchar</span></a> with the name of a <a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstElement.html"><span class="type">GstElement</span></a></p></td>
<td class="parameter_annotations"> </td>
</tr>
</tbody>
</table></div>
</div>
<p class="since">Since: <a class="link" href="ix03.html#api-index-1.6">1.6</a></p>
</div>
<hr>
<div class="refsect2">
<a name="gst-harness-push-to-sink"></a><h3>gst_harness_push_to_sink ()</h3>
<pre class="programlisting"><a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstPad.html#GstFlowReturn"><span class="returnvalue">GstFlowReturn</span></a>
gst_harness_push_to_sink (<em class="parameter"><code><a class="link" href="gstreamer-libs-GstHarness.html#GstHarness" title="struct GstHarness"><span class="type">GstHarness</span></a> *h</code></em>);</pre>
<p>Transfer one <a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstBuffer.html"><span class="type">GstBuffer</span></a> from the main-<a class="link" href="gstreamer-libs-GstHarness.html#GstHarness" title="struct GstHarness"><span class="type">GstHarness</span></a> to the sink-<a class="link" href="gstreamer-libs-GstHarness.html#GstHarness" title="struct GstHarness"><span class="type">GstHarness</span></a>.
See gst_harness_push_from_src for details.</p>
<p>MT safe.</p>
<div class="refsect3">
<a name="id-1.2.7.6.7.60.6"></a><h4>Parameters</h4>
<div class="informaltable"><table width="100%" border="0">
<colgroup>
<col width="150px" class="parameters_name">
<col class="parameters_description">
<col width="200px" class="parameters_annotations">
</colgroup>
<tbody><tr>
<td class="parameter_name"><p>h</p></td>
<td class="parameter_description"><p>a <a class="link" href="gstreamer-libs-GstHarness.html#GstHarness" title="struct GstHarness"><span class="type">GstHarness</span></a></p></td>
<td class="parameter_annotations"> </td>
</tr></tbody>
</table></div>
</div>
<div class="refsect3">
<a name="id-1.2.7.6.7.60.7"></a><h4>Returns</h4>
<p> a <a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstPad.html#GstFlowReturn"><span class="type">GstFlowReturn</span></a> with the result of the push</p>
</div>
<p class="since">Since: <a class="link" href="ix03.html#api-index-1.6">1.6</a></p>
</div>
<hr>
<div class="refsect2">
<a name="gst-harness-sink-push-many"></a><h3>gst_harness_sink_push_many ()</h3>
<pre class="programlisting"><a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstPad.html#GstFlowReturn"><span class="returnvalue">GstFlowReturn</span></a>
gst_harness_sink_push_many (<em class="parameter"><code><a class="link" href="gstreamer-libs-GstHarness.html#GstHarness" title="struct GstHarness"><span class="type">GstHarness</span></a> *h</code></em>,
<em class="parameter"><code><a href="https://developer.gnome.org/glib/unstable/glib-Basic-Types.html#gint"><span class="type">gint</span></a> pushes</code></em>);</pre>
<p>Convenience that calls gst_harness_push_to_sink <em class="parameter"><code>pushes</code></em>
number of times.
Will abort the pushing if any one push fails.</p>
<p>MT safe.</p>
<div class="refsect3">
<a name="id-1.2.7.6.7.61.6"></a><h4>Parameters</h4>
<div class="informaltable"><table width="100%" border="0">
<colgroup>
<col width="150px" class="parameters_name">
<col class="parameters_description">
<col width="200px" class="parameters_annotations">
</colgroup>
<tbody>
<tr>
<td class="parameter_name"><p>h</p></td>
<td class="parameter_description"><p>a <a class="link" href="gstreamer-libs-GstHarness.html#GstHarness" title="struct GstHarness"><span class="type">GstHarness</span></a></p></td>
<td class="parameter_annotations"> </td>
</tr>
<tr>
<td class="parameter_name"><p>pushes</p></td>
<td class="parameter_description"><p>a <a href="https://developer.gnome.org/glib/unstable/glib-Basic-Types.html#gint"><span class="type">gint</span></a> with the number of calls to gst_harness_push_to_sink</p></td>
<td class="parameter_annotations"> </td>
</tr>
</tbody>
</table></div>
</div>
<div class="refsect3">
<a name="id-1.2.7.6.7.61.7"></a><h4>Returns</h4>
<p> a <a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstPad.html#GstFlowReturn"><span class="type">GstFlowReturn</span></a> with the result of the push</p>
</div>
<p class="since">Since: <a class="link" href="ix03.html#api-index-1.6">1.6</a></p>
</div>
<hr>
<div class="refsect2">
<a name="gst-harness-find-element"></a><h3>gst_harness_find_element ()</h3>
<pre class="programlisting"><a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstElement.html"><span class="returnvalue">GstElement</span></a> *
gst_harness_find_element (<em class="parameter"><code><a class="link" href="gstreamer-libs-GstHarness.html#GstHarness" title="struct GstHarness"><span class="type">GstHarness</span></a> *h</code></em>,
<em class="parameter"><code>const <a href="https://developer.gnome.org/glib/unstable/glib-Basic-Types.html#gchar"><span class="type">gchar</span></a> *element_name</code></em>);</pre>
<p>Most useful in conjunction with gst_harness_new_parse, this will scan the
<a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstElement.html"><span class="type">GstElements</span></a> inside the <a class="link" href="gstreamer-libs-GstHarness.html#GstHarness" title="struct GstHarness"><span class="type">GstHarness</span></a>, and check if any of them matches
<em class="parameter"><code>element_name</code></em>
. Typical usecase being that you need to access one of the
harnessed elements for properties and/or signals.</p>
<p>MT safe.</p>
<div class="refsect3">
<a name="id-1.2.7.6.7.62.6"></a><h4>Parameters</h4>
<div class="informaltable"><table width="100%" border="0">
<colgroup>
<col width="150px" class="parameters_name">
<col class="parameters_description">
<col width="200px" class="parameters_annotations">
</colgroup>
<tbody>
<tr>
<td class="parameter_name"><p>h</p></td>
<td class="parameter_description"><p>a <a class="link" href="gstreamer-libs-GstHarness.html#GstHarness" title="struct GstHarness"><span class="type">GstHarness</span></a></p></td>
<td class="parameter_annotations"> </td>
</tr>
<tr>
<td class="parameter_name"><p>element_name</p></td>
<td class="parameter_description"><p>a <a href="https://developer.gnome.org/glib/unstable/glib-Basic-Types.html#gchar"><span class="type">gchar</span></a> with a <a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstElementFactory.html"><span class="type">GstElementFactory</span></a> name</p></td>
<td class="parameter_annotations"> </td>
</tr>
</tbody>
</table></div>
</div>
<div class="refsect3">
<a name="id-1.2.7.6.7.62.7"></a><h4>Returns</h4>
<p> a <a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstElement.html"><span class="type">GstElement</span></a> or <a href="https://developer.gnome.org/glib/unstable/glib-Standard-Macros.html#NULL:CAPS"><code class="literal">NULL</code></a> if not found. </p>
<p><span class="annotation">[<acronym title="Free data after the code is done."><span class="acronym">transfer full</span></acronym>][<acronym title="NULL is OK, both for passing and for returning."><span class="acronym">allow-none</span></acronym>]</span></p>
</div>
<p class="since">Since: <a class="link" href="ix03.html#api-index-1.6">1.6</a></p>
</div>
<hr>
<div class="refsect2">
<a name="gst-harness-set"></a><h3>gst_harness_set ()</h3>
<pre class="programlisting"><span class="returnvalue">void</span>
gst_harness_set (<em class="parameter"><code><a class="link" href="gstreamer-libs-GstHarness.html#GstHarness" title="struct GstHarness"><span class="type">GstHarness</span></a> *h</code></em>,
<em class="parameter"><code>const <a href="https://developer.gnome.org/glib/unstable/glib-Basic-Types.html#gchar"><span class="type">gchar</span></a> *element_name</code></em>,
<em class="parameter"><code>const <a href="https://developer.gnome.org/glib/unstable/glib-Basic-Types.html#gchar"><span class="type">gchar</span></a> *first_property_name</code></em>,
<em class="parameter"><code>...</code></em>);</pre>
<p>A convenience function to allows you to call g_object_set on a <a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstElement.html"><span class="type">GstElement</span></a>
that are residing inside the <a class="link" href="gstreamer-libs-GstHarness.html#GstHarness" title="struct GstHarness"><span class="type">GstHarness</span></a>, by using normal g_object_set
syntax.</p>
<p>MT safe.</p>
<div class="refsect3">
<a name="id-1.2.7.6.7.63.6"></a><h4>Parameters</h4>
<div class="informaltable"><table width="100%" border="0">
<colgroup>
<col width="150px" class="parameters_name">
<col class="parameters_description">
<col width="200px" class="parameters_annotations">
</colgroup>
<tbody>
<tr>
<td class="parameter_name"><p>h</p></td>
<td class="parameter_description"><p>a <a class="link" href="gstreamer-libs-GstHarness.html#GstHarness" title="struct GstHarness"><span class="type">GstHarness</span></a></p></td>
<td class="parameter_annotations"> </td>
</tr>
<tr>
<td class="parameter_name"><p>element_name</p></td>
<td class="parameter_description"><p>a <a href="https://developer.gnome.org/glib/unstable/glib-Basic-Types.html#gchar"><span class="type">gchar</span></a> with a <a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstElementFactory.html"><span class="type">GstElementFactory</span></a> name</p></td>
<td class="parameter_annotations"> </td>
</tr>
<tr>
<td class="parameter_name"><p>first_property_name</p></td>
<td class="parameter_description"><p>a <a href="https://developer.gnome.org/glib/unstable/glib-Basic-Types.html#gchar"><span class="type">gchar</span></a> with the first property name</p></td>
<td class="parameter_annotations"> </td>
</tr>
<tr>
<td class="parameter_name"><p>...</p></td>
<td class="parameter_description"><p>value for the first property, followed optionally by more
name/value pairs, followed by <a href="https://developer.gnome.org/glib/unstable/glib-Standard-Macros.html#NULL:CAPS"><code class="literal">NULL</code></a></p></td>
<td class="parameter_annotations"> </td>
</tr>
</tbody>
</table></div>
</div>
<p class="since">Since: <a class="link" href="ix03.html#api-index-1.6">1.6</a></p>
</div>
<hr>
<div class="refsect2">
<a name="gst-harness-get"></a><h3>gst_harness_get ()</h3>
<pre class="programlisting"><span class="returnvalue">void</span>
gst_harness_get (<em class="parameter"><code><a class="link" href="gstreamer-libs-GstHarness.html#GstHarness" title="struct GstHarness"><span class="type">GstHarness</span></a> *h</code></em>,
<em class="parameter"><code>const <a href="https://developer.gnome.org/glib/unstable/glib-Basic-Types.html#gchar"><span class="type">gchar</span></a> *element_name</code></em>,
<em class="parameter"><code>const <a href="https://developer.gnome.org/glib/unstable/glib-Basic-Types.html#gchar"><span class="type">gchar</span></a> *first_property_name</code></em>,
<em class="parameter"><code>...</code></em>);</pre>
<p>A convenience function to allows you to call g_object_get on a <a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstElement.html"><span class="type">GstElement</span></a>
that are residing inside the <a class="link" href="gstreamer-libs-GstHarness.html#GstHarness" title="struct GstHarness"><span class="type">GstHarness</span></a>, by using normal g_object_get
syntax.</p>
<p>MT safe.</p>
<div class="refsect3">
<a name="id-1.2.7.6.7.64.6"></a><h4>Parameters</h4>
<div class="informaltable"><table width="100%" border="0">
<colgroup>
<col width="150px" class="parameters_name">
<col class="parameters_description">
<col width="200px" class="parameters_annotations">
</colgroup>
<tbody>
<tr>
<td class="parameter_name"><p>h</p></td>
<td class="parameter_description"><p>a <a class="link" href="gstreamer-libs-GstHarness.html#GstHarness" title="struct GstHarness"><span class="type">GstHarness</span></a></p></td>
<td class="parameter_annotations"> </td>
</tr>
<tr>
<td class="parameter_name"><p>element_name</p></td>
<td class="parameter_description"><p>a <a href="https://developer.gnome.org/glib/unstable/glib-Basic-Types.html#gchar"><span class="type">gchar</span></a> with a <a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstElementFactory.html"><span class="type">GstElementFactory</span></a> name</p></td>
<td class="parameter_annotations"> </td>
</tr>
<tr>
<td class="parameter_name"><p>first_property_name</p></td>
<td class="parameter_description"><p>a <a href="https://developer.gnome.org/glib/unstable/glib-Basic-Types.html#gchar"><span class="type">gchar</span></a> with the first property name</p></td>
<td class="parameter_annotations"> </td>
</tr>
<tr>
<td class="parameter_name"><p>...</p></td>
<td class="parameter_description"><p>return location for the first property, followed optionally by more
name/return location pairs, followed by <a href="https://developer.gnome.org/glib/unstable/glib-Standard-Macros.html#NULL:CAPS"><code class="literal">NULL</code></a></p></td>
<td class="parameter_annotations"> </td>
</tr>
</tbody>
</table></div>
</div>
<p class="since">Since: <a class="link" href="ix03.html#api-index-1.6">1.6</a></p>
</div>
<hr>
<div class="refsect2">
<a name="gst-harness-add-probe"></a><h3>gst_harness_add_probe ()</h3>
<pre class="programlisting"><span class="returnvalue">void</span>
gst_harness_add_probe (<em class="parameter"><code><a class="link" href="gstreamer-libs-GstHarness.html#GstHarness" title="struct GstHarness"><span class="type">GstHarness</span></a> *h</code></em>,
<em class="parameter"><code>const <a href="https://developer.gnome.org/glib/unstable/glib-Basic-Types.html#gchar"><span class="type">gchar</span></a> *element_name</code></em>,
<em class="parameter"><code>const <a href="https://developer.gnome.org/glib/unstable/glib-Basic-Types.html#gchar"><span class="type">gchar</span></a> *pad_name</code></em>,
<em class="parameter"><code><a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstPad.html#GstPadProbeType"><span class="type">GstPadProbeType</span></a> mask</code></em>,
<em class="parameter"><code><a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstPad.html#GstPadProbeCallback"><span class="type">GstPadProbeCallback</span></a> callback</code></em>,
<em class="parameter"><code><a href="https://developer.gnome.org/glib/unstable/glib-Basic-Types.html#gpointer"><span class="type">gpointer</span></a> user_data</code></em>,
<em class="parameter"><code><a href="https://developer.gnome.org/glib/unstable/glib-Datasets.html#GDestroyNotify"><span class="type">GDestroyNotify</span></a> destroy_data</code></em>);</pre>
<p>A convenience function to allows you to call gst_pad_add_probe on a
<a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstPad.html"><span class="type">GstPad</span></a> of a <a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstElement.html"><span class="type">GstElement</span></a> that are residing inside the <a class="link" href="gstreamer-libs-GstHarness.html#GstHarness" title="struct GstHarness"><span class="type">GstHarness</span></a>,
by using normal gst_pad_add_probe syntax</p>
<p>MT safe.</p>
<div class="refsect3">
<a name="id-1.2.7.6.7.65.6"></a><h4>Parameters</h4>
<div class="informaltable"><table width="100%" border="0">
<colgroup>
<col width="150px" class="parameters_name">
<col class="parameters_description">
<col width="200px" class="parameters_annotations">
</colgroup>
<tbody>
<tr>
<td class="parameter_name"><p>h</p></td>
<td class="parameter_description"><p>a <a class="link" href="gstreamer-libs-GstHarness.html#GstHarness" title="struct GstHarness"><span class="type">GstHarness</span></a></p></td>
<td class="parameter_annotations"> </td>
</tr>
<tr>
<td class="parameter_name"><p>element_name</p></td>
<td class="parameter_description"><p>a <a href="https://developer.gnome.org/glib/unstable/glib-Basic-Types.html#gchar"><span class="type">gchar</span></a> with a <a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstElementFactory.html"><span class="type">GstElementFactory</span></a> name</p></td>
<td class="parameter_annotations"> </td>
</tr>
<tr>
<td class="parameter_name"><p>pad_name</p></td>
<td class="parameter_description"><p>a <a href="https://developer.gnome.org/glib/unstable/glib-Basic-Types.html#gchar"><span class="type">gchar</span></a> with the name of the pad to attach the probe to</p></td>
<td class="parameter_annotations"> </td>
</tr>
<tr>
<td class="parameter_name"><p>mask</p></td>
<td class="parameter_description"><p>a <a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstPad.html#GstPadProbeType"><span class="type">GstPadProbeType</span></a> (see gst_pad_add_probe)</p></td>
<td class="parameter_annotations"> </td>
</tr>
<tr>
<td class="parameter_name"><p>callback</p></td>
<td class="parameter_description"><p>a <a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstPad.html#GstPadProbeCallback"><span class="type">GstPadProbeCallback</span></a> (see gst_pad_add_probe)</p></td>
<td class="parameter_annotations"> </td>
</tr>
<tr>
<td class="parameter_name"><p>user_data</p></td>
<td class="parameter_description"><p>a <a href="https://developer.gnome.org/glib/unstable/glib-Basic-Types.html#gpointer"><span class="type">gpointer</span></a> (see gst_pad_add_probe)</p></td>
<td class="parameter_annotations"> </td>
</tr>
<tr>
<td class="parameter_name"><p>destroy_data</p></td>
<td class="parameter_description"><p>a <a href="https://developer.gnome.org/glib/unstable/glib-Datasets.html#GDestroyNotify"><span class="type">GDestroyNotify</span></a> (see gst_pad_add_probe)</p></td>
<td class="parameter_annotations"> </td>
</tr>
</tbody>
</table></div>
</div>
<p class="since">Since: <a class="link" href="ix03.html#api-index-1.6">1.6</a></p>
</div>
<hr>
<div class="refsect2">
<a name="gst-harness-stress-thread-stop"></a><h3>gst_harness_stress_thread_stop ()</h3>
<pre class="programlisting"><a href="https://developer.gnome.org/glib/unstable/glib-Basic-Types.html#guint"><span class="returnvalue">guint</span></a>
gst_harness_stress_thread_stop (<em class="parameter"><code><a class="link" href="gstreamer-libs-GstHarness.html#GstHarnessThread" title="GstHarnessThread"><span class="type">GstHarnessThread</span></a> *t</code></em>);</pre>
<p>Stop the running <a class="link" href="gstreamer-libs-GstHarness.html#GstHarnessThread" title="GstHarnessThread"><span class="type">GstHarnessThread</span></a></p>
<p>MT safe.</p>
<div class="refsect3">
<a name="id-1.2.7.6.7.66.6"></a><h4>Parameters</h4>
<div class="informaltable"><table width="100%" border="0">
<colgroup>
<col width="150px" class="parameters_name">
<col class="parameters_description">
<col width="200px" class="parameters_annotations">
</colgroup>
<tbody><tr>
<td class="parameter_name"><p>t</p></td>
<td class="parameter_description"><p>a <a class="link" href="gstreamer-libs-GstHarness.html#GstHarnessThread" title="GstHarnessThread"><span class="type">GstHarnessThread</span></a></p></td>
<td class="parameter_annotations"> </td>
</tr></tbody>
</table></div>
</div>
<p class="since">Since: <a class="link" href="ix03.html#api-index-1.6">1.6</a></p>
</div>
<hr>
<div class="refsect2">
<a name="gst-harness-stress-custom-start"></a><h3>gst_harness_stress_custom_start ()</h3>
<pre class="programlisting"><a class="link" href="gstreamer-libs-GstHarness.html#GstHarnessThread" title="GstHarnessThread"><span class="returnvalue">GstHarnessThread</span></a> *
gst_harness_stress_custom_start (<em class="parameter"><code><a class="link" href="gstreamer-libs-GstHarness.html#GstHarness" title="struct GstHarness"><span class="type">GstHarness</span></a> *h</code></em>,
<em class="parameter"><code><a href="https://developer.gnome.org/glib/unstable/glib-Doubly-Linked-Lists.html#GFunc"><span class="type">GFunc</span></a> init</code></em>,
<em class="parameter"><code><a href="https://developer.gnome.org/glib/unstable/glib-Doubly-Linked-Lists.html#GFunc"><span class="type">GFunc</span></a> callback</code></em>,
<em class="parameter"><code><a href="https://developer.gnome.org/glib/unstable/glib-Basic-Types.html#gpointer"><span class="type">gpointer</span></a> data</code></em>,
<em class="parameter"><code><a href="https://developer.gnome.org/glib/unstable/glib-Basic-Types.html#gulong"><span class="type">gulong</span></a> sleep</code></em>);</pre>
<p>Start a custom stress-thread that will call your <em class="parameter"><code>callback</code></em>
for every
iteration allowing you to do something nasty.</p>
<p>MT safe.</p>
<p><span class="annotation">[<acronym title="Exposed in C code, not necessarily available in other languages."><span class="acronym">skip</span></acronym>]</span></p>
<div class="refsect3">
<a name="id-1.2.7.6.7.67.7"></a><h4>Parameters</h4>
<div class="informaltable"><table width="100%" border="0">
<colgroup>
<col width="150px" class="parameters_name">
<col class="parameters_description">
<col width="200px" class="parameters_annotations">
</colgroup>
<tbody>
<tr>
<td class="parameter_name"><p>h</p></td>
<td class="parameter_description"><p>a <a class="link" href="gstreamer-libs-GstHarness.html#GstHarness" title="struct GstHarness"><span class="type">GstHarness</span></a></p></td>
<td class="parameter_annotations"> </td>
</tr>
<tr>
<td class="parameter_name"><p>init</p></td>
<td class="parameter_description"><p> a <a href="https://developer.gnome.org/glib/unstable/glib-Doubly-Linked-Lists.html#GFunc"><span class="type">GFunc</span></a> that is called initially and only once. </p></td>
<td class="parameter_annotations"><span class="annotation">[<acronym title="NULL is OK, both for passing and for returning."><span class="acronym">allow-none</span></acronym>]</span></td>
</tr>
<tr>
<td class="parameter_name"><p>callback</p></td>
<td class="parameter_description"><p>a <a href="https://developer.gnome.org/glib/unstable/glib-Doubly-Linked-Lists.html#GFunc"><span class="type">GFunc</span></a> that is called as often as possible</p></td>
<td class="parameter_annotations"> </td>
</tr>
<tr>
<td class="parameter_name"><p>data</p></td>
<td class="parameter_description"><p>a <a href="https://developer.gnome.org/glib/unstable/glib-Basic-Types.html#gpointer"><span class="type">gpointer</span></a> with custom data to pass to the <em class="parameter"><code>callback</code></em>
function</p></td>
<td class="parameter_annotations"> </td>
</tr>
<tr>
<td class="parameter_name"><p>sleep</p></td>
<td class="parameter_description"><p>a <a href="https://developer.gnome.org/glib/unstable/glib-Basic-Types.html#gulong"><span class="type">gulong</span></a> specifying how long to sleep in (microseconds) for
each call to the <em class="parameter"><code>callback</code></em>
</p></td>
<td class="parameter_annotations"> </td>
</tr>
</tbody>
</table></div>
</div>
<div class="refsect3">
<a name="id-1.2.7.6.7.67.8"></a><h4>Returns</h4>
<p> a <a class="link" href="gstreamer-libs-GstHarness.html#GstHarnessThread" title="GstHarnessThread"><span class="type">GstHarnessThread</span></a></p>
</div>
<p class="since">Since: <a class="link" href="ix03.html#api-index-1.6">1.6</a></p>
</div>
<hr>
<div class="refsect2">
<a name="gst-harness-stress-statechange-start"></a><h3>gst_harness_stress_statechange_start()</h3>
<pre class="programlisting">#define gst_harness_stress_statechange_start(h)</pre>
</div>
<hr>
<div class="refsect2">
<a name="gst-harness-stress-statechange-start-full"></a><h3>gst_harness_stress_statechange_start_full ()</h3>
<pre class="programlisting"><a class="link" href="gstreamer-libs-GstHarness.html#GstHarnessThread" title="GstHarnessThread"><span class="returnvalue">GstHarnessThread</span></a> *
gst_harness_stress_statechange_start_full
(<em class="parameter"><code><a class="link" href="gstreamer-libs-GstHarness.html#GstHarness" title="struct GstHarness"><span class="type">GstHarness</span></a> *h</code></em>,
<em class="parameter"><code><a href="https://developer.gnome.org/glib/unstable/glib-Basic-Types.html#gulong"><span class="type">gulong</span></a> sleep</code></em>);</pre>
<p>Change the state of your harnessed <a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstElement.html"><span class="type">GstElement</span></a> from NULL to PLAYING and
back again, only pausing for <em class="parameter"><code>sleep</code></em>
microseconds every time.</p>
<p>MT safe.</p>
<p><span class="annotation">[<acronym title="Exposed in C code, not necessarily available in other languages."><span class="acronym">skip</span></acronym>]</span></p>
<div class="refsect3">
<a name="id-1.2.7.6.7.69.7"></a><h4>Parameters</h4>
<div class="informaltable"><table width="100%" border="0">
<colgroup>
<col width="150px" class="parameters_name">
<col class="parameters_description">
<col width="200px" class="parameters_annotations">
</colgroup>
<tbody>
<tr>
<td class="parameter_name"><p>h</p></td>
<td class="parameter_description"><p>a <a class="link" href="gstreamer-libs-GstHarness.html#GstHarness" title="struct GstHarness"><span class="type">GstHarness</span></a></p></td>
<td class="parameter_annotations"> </td>
</tr>
<tr>
<td class="parameter_name"><p>sleep</p></td>
<td class="parameter_description"><p>a <a href="https://developer.gnome.org/glib/unstable/glib-Basic-Types.html#gulong"><span class="type">gulong</span></a> specifying how long to sleep in (microseconds) for
each state-change</p></td>
<td class="parameter_annotations"> </td>
</tr>
</tbody>
</table></div>
</div>
<div class="refsect3">
<a name="id-1.2.7.6.7.69.8"></a><h4>Returns</h4>
<p> a <a class="link" href="gstreamer-libs-GstHarness.html#GstHarnessThread" title="GstHarnessThread"><span class="type">GstHarnessThread</span></a></p>
</div>
<p class="since">Since: <a class="link" href="ix03.html#api-index-1.6">1.6</a></p>
</div>
<hr>
<div class="refsect2">
<a name="gst-harness-stress-push-buffer-start"></a><h3>gst_harness_stress_push_buffer_start()</h3>
<pre class="programlisting">#define gst_harness_stress_push_buffer_start(h, c, s, b)</pre>
</div>
<hr>
<div class="refsect2">
<a name="gst-harness-stress-push-buffer-start-full"></a><h3>gst_harness_stress_push_buffer_start_full ()</h3>
<pre class="programlisting"><a class="link" href="gstreamer-libs-GstHarness.html#GstHarnessThread" title="GstHarnessThread"><span class="returnvalue">GstHarnessThread</span></a> *
gst_harness_stress_push_buffer_start_full
(<em class="parameter"><code><a class="link" href="gstreamer-libs-GstHarness.html#GstHarness" title="struct GstHarness"><span class="type">GstHarness</span></a> *h</code></em>,
<em class="parameter"><code><a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstCaps.html"><span class="type">GstCaps</span></a> *caps</code></em>,
<em class="parameter"><code>const <a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstSegment.html"><span class="type">GstSegment</span></a> *segment</code></em>,
<em class="parameter"><code><a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstBuffer.html"><span class="type">GstBuffer</span></a> *buf</code></em>,
<em class="parameter"><code><a href="https://developer.gnome.org/glib/unstable/glib-Basic-Types.html#gulong"><span class="type">gulong</span></a> sleep</code></em>);</pre>
<p>Push a <a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstBuffer.html"><span class="type">GstBuffer</span></a> in intervals of <em class="parameter"><code>sleep</code></em>
microseconds.</p>
<p>MT safe.</p>
<p><span class="annotation">[<acronym title="Exposed in C code, not necessarily available in other languages."><span class="acronym">skip</span></acronym>]</span></p>
<div class="refsect3">
<a name="id-1.2.7.6.7.71.7"></a><h4>Parameters</h4>
<div class="informaltable"><table width="100%" border="0">
<colgroup>
<col width="150px" class="parameters_name">
<col class="parameters_description">
<col width="200px" class="parameters_annotations">
</colgroup>
<tbody>
<tr>
<td class="parameter_name"><p>h</p></td>
<td class="parameter_description"><p>a <a class="link" href="gstreamer-libs-GstHarness.html#GstHarness" title="struct GstHarness"><span class="type">GstHarness</span></a></p></td>
<td class="parameter_annotations"> </td>
</tr>
<tr>
<td class="parameter_name"><p>caps</p></td>
<td class="parameter_description"><p>a <a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstCaps.html"><span class="type">GstCaps</span></a> for the <a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstBuffer.html"><span class="type">GstBuffer</span></a></p></td>
<td class="parameter_annotations"> </td>
</tr>
<tr>
<td class="parameter_name"><p>segment</p></td>
<td class="parameter_description"><p>a <a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstSegment.html"><span class="type">GstSegment</span></a></p></td>
<td class="parameter_annotations"> </td>
</tr>
<tr>
<td class="parameter_name"><p>buf</p></td>
<td class="parameter_description"><p>a <a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstBuffer.html"><span class="type">GstBuffer</span></a> to push</p></td>
<td class="parameter_annotations"> </td>
</tr>
<tr>
<td class="parameter_name"><p>sleep</p></td>
<td class="parameter_description"><p>a <a href="https://developer.gnome.org/glib/unstable/glib-Basic-Types.html#gulong"><span class="type">gulong</span></a> specifying how long to sleep in (microseconds) for
each call to gst_pad_push</p></td>
<td class="parameter_annotations"> </td>
</tr>
</tbody>
</table></div>
</div>
<div class="refsect3">
<a name="id-1.2.7.6.7.71.8"></a><h4>Returns</h4>
<p> a <a class="link" href="gstreamer-libs-GstHarness.html#GstHarnessThread" title="GstHarnessThread"><span class="type">GstHarnessThread</span></a></p>
</div>
<p class="since">Since: <a class="link" href="ix03.html#api-index-1.6">1.6</a></p>
</div>
<hr>
<div class="refsect2">
<a name="GstHarnessPrepareBufferFunc"></a><h3>GstHarnessPrepareBufferFunc ()</h3>
<pre class="programlisting"><a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstBuffer.html"><span class="returnvalue">GstBuffer</span></a> *
<span class="c_punctuation">(</span>*GstHarnessPrepareBufferFunc<span class="c_punctuation">)</span> (<em class="parameter"><code><a class="link" href="gstreamer-libs-GstHarness.html#GstHarness" title="struct GstHarness"><span class="type">GstHarness</span></a> *h</code></em>,
<em class="parameter"><code><a href="https://developer.gnome.org/glib/unstable/glib-Basic-Types.html#gpointer"><span class="type">gpointer</span></a> data</code></em>);</pre>
<div class="refsect3">
<a name="id-1.2.7.6.7.72.4"></a><h4>Parameters</h4>
<div class="informaltable"><table width="100%" border="0">
<colgroup>
<col width="150px" class="parameters_name">
<col class="parameters_description">
<col width="200px" class="parameters_annotations">
</colgroup>
<tbody>
<tr>
<td class="parameter_name"><p>h</p></td>
<td class="parameter_description"><p>a <a class="link" href="gstreamer-libs-GstHarness.html#GstHarness" title="struct GstHarness"><span class="type">GstHarness</span></a></p></td>
<td class="parameter_annotations"> </td>
</tr>
<tr>
<td class="parameter_name"><p>data</p></td>
<td class="parameter_description"><p>user data</p></td>
<td class="parameter_annotations"> </td>
</tr>
</tbody>
</table></div>
</div>
<p class="since">Since: <a class="link" href="ix03.html#api-index-1.6">1.6</a></p>
</div>
<hr>
<div class="refsect2">
<a name="gst-harness-stress-push-buffer-with-cb-start"></a><h3>gst_harness_stress_push_buffer_with_cb_start()</h3>
<pre class="programlisting">#define gst_harness_stress_push_buffer_with_cb_start(h, c, s, f, d, n)</pre>
</div>
<hr>
<div class="refsect2">
<a name="gst-harness-stress-push-buffer-with-cb-start-full"></a><h3>gst_harness_stress_push_buffer_with_cb_start_full ()</h3>
<pre class="programlisting"><a class="link" href="gstreamer-libs-GstHarness.html#GstHarnessThread" title="GstHarnessThread"><span class="returnvalue">GstHarnessThread</span></a> *
gst_harness_stress_push_buffer_with_cb_start_full
(<em class="parameter"><code><a class="link" href="gstreamer-libs-GstHarness.html#GstHarness" title="struct GstHarness"><span class="type">GstHarness</span></a> *h</code></em>,
<em class="parameter"><code><a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstCaps.html"><span class="type">GstCaps</span></a> *caps</code></em>,
<em class="parameter"><code>const <a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstSegment.html"><span class="type">GstSegment</span></a> *segment</code></em>,
<em class="parameter"><code><a class="link" href="gstreamer-libs-GstHarness.html#GstHarnessPrepareBufferFunc" title="GstHarnessPrepareBufferFunc ()"><span class="type">GstHarnessPrepareBufferFunc</span></a> func</code></em>,
<em class="parameter"><code><a href="https://developer.gnome.org/glib/unstable/glib-Basic-Types.html#gpointer"><span class="type">gpointer</span></a> data</code></em>,
<em class="parameter"><code><a href="https://developer.gnome.org/glib/unstable/glib-Datasets.html#GDestroyNotify"><span class="type">GDestroyNotify</span></a> notify</code></em>,
<em class="parameter"><code><a href="https://developer.gnome.org/glib/unstable/glib-Basic-Types.html#gulong"><span class="type">gulong</span></a> sleep</code></em>);</pre>
<p>Push a <a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstBuffer.html"><span class="type">GstBuffer</span></a> in intervals of <em class="parameter"><code>sleep</code></em>
microseconds.</p>
<p>MT safe.</p>
<p><span class="annotation">[<acronym title="Exposed in C code, not necessarily available in other languages."><span class="acronym">skip</span></acronym>]</span></p>
<div class="refsect3">
<a name="id-1.2.7.6.7.74.7"></a><h4>Parameters</h4>
<div class="informaltable"><table width="100%" border="0">
<colgroup>
<col width="150px" class="parameters_name">
<col class="parameters_description">
<col width="200px" class="parameters_annotations">
</colgroup>
<tbody>
<tr>
<td class="parameter_name"><p>h</p></td>
<td class="parameter_description"><p>a <a class="link" href="gstreamer-libs-GstHarness.html#GstHarness" title="struct GstHarness"><span class="type">GstHarness</span></a></p></td>
<td class="parameter_annotations"> </td>
</tr>
<tr>
<td class="parameter_name"><p>caps</p></td>
<td class="parameter_description"><p>a <a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstCaps.html"><span class="type">GstCaps</span></a> for the <a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstBuffer.html"><span class="type">GstBuffer</span></a></p></td>
<td class="parameter_annotations"> </td>
</tr>
<tr>
<td class="parameter_name"><p>segment</p></td>
<td class="parameter_description"><p>a <a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstSegment.html"><span class="type">GstSegment</span></a></p></td>
<td class="parameter_annotations"> </td>
</tr>
<tr>
<td class="parameter_name"><p>func</p></td>
<td class="parameter_description"><p>a <a class="link" href="gstreamer-libs-GstHarness.html#GstHarnessPrepareBufferFunc" title="GstHarnessPrepareBufferFunc ()"><span class="type">GstHarnessPrepareBufferFunc</span></a> function called before every iteration
to prepare / create a <a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstBuffer.html"><span class="type">GstBuffer</span></a> for pushing</p></td>
<td class="parameter_annotations"> </td>
</tr>
<tr>
<td class="parameter_name"><p>data</p></td>
<td class="parameter_description"><p>a <a href="https://developer.gnome.org/glib/unstable/glib-Basic-Types.html#gpointer"><span class="type">gpointer</span></a> with data to the <a class="link" href="gstreamer-libs-GstHarness.html#GstHarnessPrepareBufferFunc" title="GstHarnessPrepareBufferFunc ()"><span class="type">GstHarnessPrepareBufferFunc</span></a> function</p></td>
<td class="parameter_annotations"> </td>
</tr>
<tr>
<td class="parameter_name"><p>notify</p></td>
<td class="parameter_description"><p>a <a href="https://developer.gnome.org/glib/unstable/glib-Datasets.html#GDestroyNotify"><span class="type">GDestroyNotify</span></a> that is called for every push to allow cleaning
up the <a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstBuffer.html"><span class="type">GstBuffer</span></a>. (like gst_buffer_unref)</p></td>
<td class="parameter_annotations"> </td>
</tr>
<tr>
<td class="parameter_name"><p>sleep</p></td>
<td class="parameter_description"><p>a <a href="https://developer.gnome.org/glib/unstable/glib-Basic-Types.html#gulong"><span class="type">gulong</span></a> specifying how long to sleep in (microseconds) for
each call to gst_pad_push</p></td>
<td class="parameter_annotations"> </td>
</tr>
</tbody>
</table></div>
</div>
<div class="refsect3">
<a name="id-1.2.7.6.7.74.8"></a><h4>Returns</h4>
<p> a <a class="link" href="gstreamer-libs-GstHarness.html#GstHarnessThread" title="GstHarnessThread"><span class="type">GstHarnessThread</span></a></p>
</div>
<p class="since">Since: <a class="link" href="ix03.html#api-index-1.6">1.6</a></p>
</div>
<hr>
<div class="refsect2">
<a name="gst-harness-stress-push-event-start"></a><h3>gst_harness_stress_push_event_start()</h3>
<pre class="programlisting">#define gst_harness_stress_push_event_start(h, e)</pre>
</div>
<hr>
<div class="refsect2">
<a name="gst-harness-stress-push-event-start-full"></a><h3>gst_harness_stress_push_event_start_full ()</h3>
<pre class="programlisting"><a class="link" href="gstreamer-libs-GstHarness.html#GstHarnessThread" title="GstHarnessThread"><span class="returnvalue">GstHarnessThread</span></a> *
gst_harness_stress_push_event_start_full
(<em class="parameter"><code><a class="link" href="gstreamer-libs-GstHarness.html#GstHarness" title="struct GstHarness"><span class="type">GstHarness</span></a> *h</code></em>,
<em class="parameter"><code><a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstEvent.html"><span class="type">GstEvent</span></a> *event</code></em>,
<em class="parameter"><code><a href="https://developer.gnome.org/glib/unstable/glib-Basic-Types.html#gulong"><span class="type">gulong</span></a> sleep</code></em>);</pre>
<p>Push the <em class="parameter"><code>event</code></em>
onto the harnessed <a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstElement.html"><span class="type">GstElement</span></a> sinkpad in intervals of
<em class="parameter"><code>sleep</code></em>
microseconds</p>
<p>MT safe.</p>
<p><span class="annotation">[<acronym title="Exposed in C code, not necessarily available in other languages."><span class="acronym">skip</span></acronym>]</span></p>
<div class="refsect3">
<a name="id-1.2.7.6.7.76.7"></a><h4>Parameters</h4>
<div class="informaltable"><table width="100%" border="0">
<colgroup>
<col width="150px" class="parameters_name">
<col class="parameters_description">
<col width="200px" class="parameters_annotations">
</colgroup>
<tbody>
<tr>
<td class="parameter_name"><p>h</p></td>
<td class="parameter_description"><p>a <a class="link" href="gstreamer-libs-GstHarness.html#GstHarness" title="struct GstHarness"><span class="type">GstHarness</span></a></p></td>
<td class="parameter_annotations"> </td>
</tr>
<tr>
<td class="parameter_name"><p>event</p></td>
<td class="parameter_description"><p>a <a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstEvent.html"><span class="type">GstEvent</span></a> to push</p></td>
<td class="parameter_annotations"> </td>
</tr>
<tr>
<td class="parameter_name"><p>sleep</p></td>
<td class="parameter_description"><p>a <a href="https://developer.gnome.org/glib/unstable/glib-Basic-Types.html#gulong"><span class="type">gulong</span></a> specifying how long to sleep in (microseconds) for
each gst_event_push with <em class="parameter"><code>event</code></em>
</p></td>
<td class="parameter_annotations"> </td>
</tr>
</tbody>
</table></div>
</div>
<div class="refsect3">
<a name="id-1.2.7.6.7.76.8"></a><h4>Returns</h4>
<p> a <a class="link" href="gstreamer-libs-GstHarness.html#GstHarnessThread" title="GstHarnessThread"><span class="type">GstHarnessThread</span></a></p>
</div>
<p class="since">Since: <a class="link" href="ix03.html#api-index-1.6">1.6</a></p>
</div>
<hr>
<div class="refsect2">
<a name="gst-harness-stress-send-upstream-event-start"></a><h3>gst_harness_stress_send_upstream_event_start()</h3>
<pre class="programlisting">#define gst_harness_stress_send_upstream_event_start(h, e)</pre>
</div>
<hr>
<div class="refsect2">
<a name="gst-harness-stress-push-upstream-event-start-full"></a><h3>gst_harness_stress_push_upstream_event_start_full ()</h3>
<pre class="programlisting"><a class="link" href="gstreamer-libs-GstHarness.html#GstHarnessThread" title="GstHarnessThread"><span class="returnvalue">GstHarnessThread</span></a> *
gst_harness_stress_push_upstream_event_start_full
(<em class="parameter"><code><a class="link" href="gstreamer-libs-GstHarness.html#GstHarness" title="struct GstHarness"><span class="type">GstHarness</span></a> *h</code></em>,
<em class="parameter"><code><a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstEvent.html"><span class="type">GstEvent</span></a> *event</code></em>,
<em class="parameter"><code><a href="https://developer.gnome.org/glib/unstable/glib-Basic-Types.html#gulong"><span class="type">gulong</span></a> sleep</code></em>);</pre>
<p>Push the <em class="parameter"><code>event</code></em>
onto the harnessed <a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstElement.html"><span class="type">GstElement</span></a> srcpad in intervals of
<em class="parameter"><code>sleep</code></em>
microseconds.
Pushing events should generally be OOB events.
If you need serialized events, you may use a custom stress thread which
both pushes buffers and events.</p>
<p>MT safe.</p>
<p><span class="annotation">[<acronym title="Exposed in C code, not necessarily available in other languages."><span class="acronym">skip</span></acronym>]</span></p>
<div class="refsect3">
<a name="id-1.2.7.6.7.78.7"></a><h4>Parameters</h4>
<div class="informaltable"><table width="100%" border="0">
<colgroup>
<col width="150px" class="parameters_name">
<col class="parameters_description">
<col width="200px" class="parameters_annotations">
</colgroup>
<tbody>
<tr>
<td class="parameter_name"><p>h</p></td>
<td class="parameter_description"><p>a <a class="link" href="gstreamer-libs-GstHarness.html#GstHarness" title="struct GstHarness"><span class="type">GstHarness</span></a></p></td>
<td class="parameter_annotations"> </td>
</tr>
<tr>
<td class="parameter_name"><p>event</p></td>
<td class="parameter_description"><p>a <a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstEvent.html"><span class="type">GstEvent</span></a> to push</p></td>
<td class="parameter_annotations"> </td>
</tr>
<tr>
<td class="parameter_name"><p>sleep</p></td>
<td class="parameter_description"><p>a <a href="https://developer.gnome.org/glib/unstable/glib-Basic-Types.html#gulong"><span class="type">gulong</span></a> specifying how long to sleep in (microseconds) for
each gst_event_push with <em class="parameter"><code>event</code></em>
</p></td>
<td class="parameter_annotations"> </td>
</tr>
</tbody>
</table></div>
</div>
<div class="refsect3">
<a name="id-1.2.7.6.7.78.8"></a><h4>Returns</h4>
<p> a <a class="link" href="gstreamer-libs-GstHarness.html#GstHarnessThread" title="GstHarnessThread"><span class="type">GstHarnessThread</span></a></p>
</div>
<p class="since">Since: <a class="link" href="ix03.html#api-index-1.6">1.6</a></p>
</div>
<hr>
<div class="refsect2">
<a name="gst-harness-stress-property-start"></a><h3>gst_harness_stress_property_start()</h3>
<pre class="programlisting">#define gst_harness_stress_property_start(h, n, v)</pre>
</div>
<hr>
<div class="refsect2">
<a name="gst-harness-stress-property-start-full"></a><h3>gst_harness_stress_property_start_full ()</h3>
<pre class="programlisting"><a class="link" href="gstreamer-libs-GstHarness.html#GstHarnessThread" title="GstHarnessThread"><span class="returnvalue">GstHarnessThread</span></a> *
gst_harness_stress_property_start_full
(<em class="parameter"><code><a class="link" href="gstreamer-libs-GstHarness.html#GstHarness" title="struct GstHarness"><span class="type">GstHarness</span></a> *h</code></em>,
<em class="parameter"><code>const <a href="https://developer.gnome.org/glib/unstable/glib-Basic-Types.html#gchar"><span class="type">gchar</span></a> *name</code></em>,
<em class="parameter"><code>const <a href="https://developer.gnome.org/gobject/unstable/gobject-Generic-values.html#GValue"><span class="type">GValue</span></a> *value</code></em>,
<em class="parameter"><code><a href="https://developer.gnome.org/glib/unstable/glib-Basic-Types.html#gulong"><span class="type">gulong</span></a> sleep</code></em>);</pre>
<p>Call g_object_set with <em class="parameter"><code>name</code></em>
and <em class="parameter"><code>value</code></em>
in intervals of <em class="parameter"><code>sleep</code></em>
microseconds</p>
<p>MT safe.</p>
<p><span class="annotation">[<acronym title="Exposed in C code, not necessarily available in other languages."><span class="acronym">skip</span></acronym>]</span></p>
<div class="refsect3">
<a name="id-1.2.7.6.7.80.7"></a><h4>Parameters</h4>
<div class="informaltable"><table width="100%" border="0">
<colgroup>
<col width="150px" class="parameters_name">
<col class="parameters_description">
<col width="200px" class="parameters_annotations">
</colgroup>
<tbody>
<tr>
<td class="parameter_name"><p>h</p></td>
<td class="parameter_description"><p>a <a class="link" href="gstreamer-libs-GstHarness.html#GstHarness" title="struct GstHarness"><span class="type">GstHarness</span></a></p></td>
<td class="parameter_annotations"> </td>
</tr>
<tr>
<td class="parameter_name"><p>name</p></td>
<td class="parameter_description"><p>a <a href="https://developer.gnome.org/glib/unstable/glib-Basic-Types.html#gchar"><span class="type">gchar</span></a> specifying a property name</p></td>
<td class="parameter_annotations"> </td>
</tr>
<tr>
<td class="parameter_name"><p>value</p></td>
<td class="parameter_description"><p>a <a href="https://developer.gnome.org/gobject/unstable/gobject-Generic-values.html#GValue"><span class="type">GValue</span></a> to set the property to</p></td>
<td class="parameter_annotations"> </td>
</tr>
<tr>
<td class="parameter_name"><p>sleep</p></td>
<td class="parameter_description"><p>a <a href="https://developer.gnome.org/glib/unstable/glib-Basic-Types.html#gulong"><span class="type">gulong</span></a> specifying how long to sleep in (microseconds) for
each g_object_set with <em class="parameter"><code>name</code></em>
and <em class="parameter"><code>value</code></em>
</p></td>
<td class="parameter_annotations"> </td>
</tr>
</tbody>
</table></div>
</div>
<div class="refsect3">
<a name="id-1.2.7.6.7.80.8"></a><h4>Returns</h4>
<p> a <a class="link" href="gstreamer-libs-GstHarness.html#GstHarnessThread" title="GstHarnessThread"><span class="type">GstHarnessThread</span></a></p>
</div>
<p class="since">Since: <a class="link" href="ix03.html#api-index-1.6">1.6</a></p>
</div>
<hr>
<div class="refsect2">
<a name="gst-harness-stress-requestpad-start"></a><h3>gst_harness_stress_requestpad_start()</h3>
<pre class="programlisting">#define gst_harness_stress_requestpad_start(h, t, n, c, r)</pre>
</div>
<hr>
<div class="refsect2">
<a name="gst-harness-stress-requestpad-start-full"></a><h3>gst_harness_stress_requestpad_start_full ()</h3>
<pre class="programlisting"><a class="link" href="gstreamer-libs-GstHarness.html#GstHarnessThread" title="GstHarnessThread"><span class="returnvalue">GstHarnessThread</span></a> *
gst_harness_stress_requestpad_start_full
(<em class="parameter"><code><a class="link" href="gstreamer-libs-GstHarness.html#GstHarness" title="struct GstHarness"><span class="type">GstHarness</span></a> *h</code></em>,
<em class="parameter"><code><a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstPadTemplate.html"><span class="type">GstPadTemplate</span></a> *templ</code></em>,
<em class="parameter"><code>const <a href="https://developer.gnome.org/glib/unstable/glib-Basic-Types.html#gchar"><span class="type">gchar</span></a> *name</code></em>,
<em class="parameter"><code><a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstCaps.html"><span class="type">GstCaps</span></a> *caps</code></em>,
<em class="parameter"><code><a href="https://developer.gnome.org/glib/unstable/glib-Basic-Types.html#gboolean"><span class="type">gboolean</span></a> release</code></em>,
<em class="parameter"><code><a href="https://developer.gnome.org/glib/unstable/glib-Basic-Types.html#gulong"><span class="type">gulong</span></a> sleep</code></em>);</pre>
<p>Call gst_element_request_pad in intervals of <em class="parameter"><code>sleep</code></em>
microseconds</p>
<p>MT safe.</p>
<p><span class="annotation">[<acronym title="Exposed in C code, not necessarily available in other languages."><span class="acronym">skip</span></acronym>]</span></p>
<div class="refsect3">
<a name="id-1.2.7.6.7.82.7"></a><h4>Parameters</h4>
<div class="informaltable"><table width="100%" border="0">
<colgroup>
<col width="150px" class="parameters_name">
<col class="parameters_description">
<col width="200px" class="parameters_annotations">
</colgroup>
<tbody>
<tr>
<td class="parameter_name"><p>h</p></td>
<td class="parameter_description"><p>a <a class="link" href="gstreamer-libs-GstHarness.html#GstHarness" title="struct GstHarness"><span class="type">GstHarness</span></a></p></td>
<td class="parameter_annotations"> </td>
</tr>
<tr>
<td class="parameter_name"><p>templ</p></td>
<td class="parameter_description"><p>a <a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstPadTemplate.html"><span class="type">GstPadTemplate</span></a></p></td>
<td class="parameter_annotations"> </td>
</tr>
<tr>
<td class="parameter_name"><p>name</p></td>
<td class="parameter_description"><p>a <a href="https://developer.gnome.org/glib/unstable/glib-Basic-Types.html#gchar"><span class="type">gchar</span></a></p></td>
<td class="parameter_annotations"> </td>
</tr>
<tr>
<td class="parameter_name"><p>caps</p></td>
<td class="parameter_description"><p>a <a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstCaps.html"><span class="type">GstCaps</span></a></p></td>
<td class="parameter_annotations"> </td>
</tr>
<tr>
<td class="parameter_name"><p>release</p></td>
<td class="parameter_description"><p>a <a href="https://developer.gnome.org/glib/unstable/glib-Basic-Types.html#gboolean"><span class="type">gboolean</span></a></p></td>
<td class="parameter_annotations"> </td>
</tr>
<tr>
<td class="parameter_name"><p>sleep</p></td>
<td class="parameter_description"><p>a <a href="https://developer.gnome.org/glib/unstable/glib-Basic-Types.html#gulong"><span class="type">gulong</span></a> specifying how long to sleep in (microseconds) for
each gst_element_request_pad</p></td>
<td class="parameter_annotations"> </td>
</tr>
</tbody>
</table></div>
</div>
<div class="refsect3">
<a name="id-1.2.7.6.7.82.8"></a><h4>Returns</h4>
<p> a <a class="link" href="gstreamer-libs-GstHarness.html#GstHarnessThread" title="GstHarnessThread"><span class="type">GstHarnessThread</span></a></p>
</div>
<p class="since">Since: <a class="link" href="ix03.html#api-index-1.6">1.6</a></p>
</div>
</div>
<div class="refsect1">
<a name="gstreamer-libs-GstHarness.other_details"></a><h2>Types and Values</h2>
<div class="refsect2">
<a name="GstHarness"></a><h3>struct GstHarness</h3>
<pre class="programlisting">struct GstHarness {
GstElement * element;
GstPad * srcpad;
GstPad * sinkpad;
GstHarness * src_harness;
GstHarness * sink_harness;
};
</pre>
<div class="refsect3">
<a name="id-1.2.7.6.8.2.4"></a><h4>Members</h4>
<div class="informaltable"><table width="100%" border="0">
<colgroup>
<col width="300px" class="struct_members_name">
<col class="struct_members_description">
<col width="200px" class="struct_members_annotations">
</colgroup>
<tbody>
<tr>
<td class="struct_member_name"><p><a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstElement.html"><span class="type">GstElement</span></a> *<em class="structfield"><code><a name="GstHarness.element"></a>element</code></em>;</p></td>
<td class="struct_member_description"><p>the element inside the harness</p></td>
<td class="struct_member_annotations"> </td>
</tr>
<tr>
<td class="struct_member_name"><p><a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstPad.html"><span class="type">GstPad</span></a> *<em class="structfield"><code><a name="GstHarness.srcpad"></a>srcpad</code></em>;</p></td>
<td class="struct_member_description"><p>the internal harness source pad</p></td>
<td class="struct_member_annotations"> </td>
</tr>
<tr>
<td class="struct_member_name"><p><a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstPad.html"><span class="type">GstPad</span></a> *<em class="structfield"><code><a name="GstHarness.sinkpad"></a>sinkpad</code></em>;</p></td>
<td class="struct_member_description"><p>the internal harness sink pad</p></td>
<td class="struct_member_annotations"> </td>
</tr>
<tr>
<td class="struct_member_name"><p><a class="link" href="gstreamer-libs-GstHarness.html#GstHarness" title="struct GstHarness"><span class="type">GstHarness</span></a> *<em class="structfield"><code><a name="GstHarness.src-harness"></a>src_harness</code></em>;</p></td>
<td class="struct_member_description"><p>the source (input) harness (if any)</p></td>
<td class="struct_member_annotations"> </td>
</tr>
<tr>
<td class="struct_member_name"><p><a class="link" href="gstreamer-libs-GstHarness.html#GstHarness" title="struct GstHarness"><span class="type">GstHarness</span></a> *<em class="structfield"><code><a name="GstHarness.sink-harness"></a>sink_harness</code></em>;</p></td>
<td class="struct_member_description"><p>the sink (output) harness (if any)</p></td>
<td class="struct_member_annotations"> </td>
</tr>
</tbody>
</table></div>
</div>
<p class="since">Since: <a class="link" href="ix03.html#api-index-1.6">1.6</a></p>
</div>
<hr>
<div class="refsect2">
<a name="GstHarnessThread"></a><h3>GstHarnessThread</h3>
<pre class="programlisting">typedef struct _GstHarnessThread GstHarnessThread;</pre>
<p>Opaque handle representing a GstHarness stress testing thread.</p>
<p class="since">Since: <a class="link" href="ix03.html#api-index-1.6">1.6</a></p>
</div>
</div>
<div class="refsect1">
<a name="gstreamer-libs-GstHarness.see-also"></a><h2>See Also</h2>
<p><a class="link" href="GstTestClock.html" title="GstTestClock"><span class="type">GstTestClock</span></a>,\</p>
</div>
</div>
<div class="footer">
<hr>Generated by GTK-Doc V1.24</div>
</body>
</html>