summaryrefslogtreecommitdiff
path: root/page_remote_api.html
diff options
context:
space:
mode:
Diffstat (limited to 'page_remote_api.html')
-rw-r--r--page_remote_api.html120
1 files changed, 120 insertions, 0 deletions
diff --git a/page_remote_api.html b/page_remote_api.html
new file mode 100644
index 00000000..bc6d2b32
--- /dev/null
+++ b/page_remote_api.html
@@ -0,0 +1,120 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "https://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+<head>
+<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
+<meta http-equiv="X-UA-Compatible" content="IE=9"/>
+<meta name="generator" content="Doxygen 1.8.15"/>
+<meta name="viewport" content="width=device-width, initial-scale=1"/>
+<title>PipeWire: Remote API</title>
+<link href="tabs.css" rel="stylesheet" type="text/css"/>
+<script type="text/javascript" src="jquery.js"></script>
+<script type="text/javascript" src="dynsections.js"></script>
+<link href="navtree.css" rel="stylesheet" type="text/css"/>
+<script type="text/javascript" src="resize.js"></script>
+<script type="text/javascript" src="navtreedata.js"></script>
+<script type="text/javascript" src="navtree.js"></script>
+<script type="text/javascript">
+/* @license magnet:?xt=urn:btih:cf05388f2679ee054f2beb29a391d25f4e673ac3&amp;dn=gpl-2.0.txt GPL-v2 */
+ $(document).ready(initResizable);
+/* @license-end */</script>
+<link href="doxygen.css" rel="stylesheet" type="text/css" />
+</head>
+<body>
+<div id="top"><!-- do not remove this div, it is closed by doxygen! -->
+<div id="titlearea">
+<table cellspacing="0" cellpadding="0">
+ <tbody>
+ <tr style="height: 56px;">
+ <td id="projectalign" style="padding-left: 0.5em;">
+ <div id="projectname">PipeWire
+ &#160;<span id="projectnumber">0.2.9</span>
+ </div>
+ </td>
+ </tr>
+ </tbody>
+</table>
+</div>
+<!-- end header part -->
+<!-- Generated by Doxygen 1.8.15 -->
+<script type="text/javascript" src="menudata.js"></script>
+<script type="text/javascript" src="menu.js"></script>
+<script type="text/javascript">
+/* @license magnet:?xt=urn:btih:cf05388f2679ee054f2beb29a391d25f4e673ac3&amp;dn=gpl-2.0.txt GPL-v2 */
+$(function() {
+ initMenu('',false,false,'search.php','Search');
+});
+/* @license-end */</script>
+<div id="main-nav"></div>
+</div><!-- top -->
+<div id="side-nav" class="ui-resizable side-nav-resizable">
+ <div id="nav-tree">
+ <div id="nav-tree-contents">
+ <div id="nav-sync" class="sync"></div>
+ </div>
+ </div>
+ <div id="splitbar" style="-moz-user-select:none;"
+ class="ui-resizable-handle">
+ </div>
+</div>
+<script type="text/javascript">
+/* @license magnet:?xt=urn:btih:cf05388f2679ee054f2beb29a391d25f4e673ac3&amp;dn=gpl-2.0.txt GPL-v2 */
+$(document).ready(function(){initNavTree('page_remote_api.html','');});
+/* @license-end */
+</script>
+<div id="doc-content">
+<div class="PageDoc"><div class="header">
+ <div class="headertitle">
+<div class="title">Remote API </div> </div>
+</div><!--header-->
+<div class="contents">
+<div class="textblock"><h1><a class="anchor" id="sec_remote_api_overview"></a>
+Overview</h1>
+<p>The remote API allows you to connect to a remote PipeWire instance and perform actions on the PipeWire graph. This includes</p>
+<ul>
+<li>introspecting the objects on the instance </li>
+<li>Creating nodes </li>
+<li>Linking nodes on their ports </li>
+<li>providing media to the server for playback or consumption </li>
+<li>retrieving media from the remote instance</li>
+</ul>
+<h1><a class="anchor" id="sec_remote_api_loop"></a>
+Event Loop Abstraction</h1>
+<p>Most API is asynchronous and based around an event loop. Methods will start an operation which will cause a state change of the <a class="el" href="classpw__remote.html">pw_remote</a> object. Connect to the state_changed event to be notified of these state changes.</p>
+<p>The most convenient way to deal with the asynchronous calls is probably with the thread loop (See <a class="el" href="page_thread_loop.html">Threaded Loop</a> for more details).</p>
+<h2><a class="anchor" id="ssec_remote_api_proxy"></a>
+Proxy</h2>
+<p>Proxies are local representations of remote resources. They allow communication between local and remote objects.</p>
+<p>The <a class="el" href="classpw__remote.html">pw_remote</a> maintains a list of all proxies, including a core proxy that is used to get access to other proxy objects.</p>
+<p>See also <a class="el" href="page_proxy.html">Proxy</a></p>
+<h1><a class="anchor" id="sec_remote_api_remote"></a>
+Remote</h1>
+<h2><a class="anchor" id="ssec_remote_create"></a>
+Create</h2>
+<p>To create a new remote use <a class="el" href="classpw__remote.html#ad5f598eb7abbac2d8538992f3f6c07f7" title="Create a new unconnected remote.">pw_remote_new()</a>. You will need to pass a local <a class="el" href="classpw__core.html">pw_core</a> implementation for event and data loop.</p>
+<p>A typical loop would be created with <a class="el" href="classpw__thread__loop.html#a44be566c483a400be731a840da066cc6" title="Create a new pw_thread_loop.">pw_thread_loop_new()</a> but other implementation are possible.</p>
+<p>You will also need to pass properties for the remote. Use <a class="el" href="classpw__pipewire.html#aaa9f7d9822aeae824c0e006d34b926f5" title="Fill remote properties.">pw_fill_remote_properties()</a> to get a default set of properties.</p>
+<p>After creating the remote, you can track the state of the remote by listening for the state_changed event.</p>
+<h2><a class="anchor" id="ssec_remote_api_remote_connect"></a>
+Connecting</h2>
+<p>A remote must be connected before any operation can be issued. Calling <a class="el" href="classpw__remote.html#a2d834fb0fdcb7e2174b9c156bcc3fe69" title="Connect to a remote PipeWire.">pw_remote_connect()</a> will initiate the connection procedure.</p>
+<p>When connecting, the remote will automatically create a core proxy to get access to the registry proxy and types.</p>
+<h2><a class="anchor" id="ssec_remote_api_remote_registry"></a>
+Registry</h2>
+<p><a class="el" href="page_registry.html">Registry</a></p>
+<h2><a class="anchor" id="ssec_remote_api_remote_disconnect"></a>
+Disconnect</h2>
+<p>Use <a class="el" href="classpw__remote.html#a90de30b9f1762e327e05bf8d6a0047a4" title="Disconnect from the remote PipeWire.">pw_remote_disconnect()</a> to disconnect from the remote. </p>
+</div></div><!-- PageDoc -->
+</div><!-- contents -->
+</div><!-- doc-content -->
+<!-- start footer part -->
+<div id="nav-path" class="navpath"><!-- id is needed for treeview function! -->
+ <ul>
+ <li class="navelem"><a class="el" href="index.html">index</a></li>
+ <li class="footer">Generated by
+ <a href="http://www.doxygen.org/index.html">
+ <img class="footer" src="doxygen.png" alt="doxygen"/></a> 1.8.15 </li>
+ </ul>
+</div>
+</body>
+</html>