PipeWire 0.2.5

Data Structures | Macros | Enumerations | Functions
remote.h File Reference
Include dependency graph for remote.h:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

## Data Structures
struct | pw_remote_events
| Events for the remote. More...

## Macros
#define | PW_VERSION_REMOTE_EVENTS 0
#define | PW_REMOTE_PROP_PROTOCOL "pipewire.protocol"
| Specify the name of the protocol to use, default is using the native protocol. More...
#define | PW_REMOTE_PROP_REMOTE_NAME "pipewire.remote.name"
| The name of the remote to connect to, default env(PIPEWIRE_REMOTE) or pipewire-0. More...

## Enumerations
enum | pw_remote_state { PW_REMOTE_STATE_ERROR = -1, PW_REMOTE_STATE_UNCONNECTED = 0, PW_REMOTE_STATE_CONNECTING = 1, PW_REMOTE_STATE_CONNECTED = 2 }
| The state of a pw_remote. More...

## Functions
struct pw_core * | pw_remote_get_core (struct pw_remote *remote)
| Get the core used to construct this remote. More...
const struct pw_properties * | pw_remote_get_properties (struct pw_remote *remote)
| Get the remote properties. More...
void * | pw_remote_get_user_data (struct pw_remote *remote)
| Get the user_data. More...
enum pw_remote_state | pw_remote_get_state (struct pw_remote *remote, const char **error)
| Get the current state, error is set when state is PW_REMOTE_STATE_ERROR. More...
void | pw_remote_add_listener (struct pw_remote *remote, struct spa_hook *listener, const struct pw_remote_events *events, void *data)
| Add listener for events. More...
int | pw_remote_steal_fd (struct pw_remote *remote)
| Steal the fd of the remote connection or < 0 on error. More...
struct pw_core_proxy * | pw_remote_get_core_proxy (struct pw_remote *remote)
| Get the core proxy, can only be called when connected. More...
const struct pw_core_info * | pw_remote_get_core_info (struct pw_remote *remote)
| Get the remote core info, can only be called when connected. More...
struct pw_proxy * | pw_remote_find_proxy (struct pw_remote *remote, uint32_t id)
| Get the proxy with the given id. More...
struct pw_proxy * | pw_remote_export (struct pw_remote *remote, struct pw_node *node)
| run a local node in a remote graph More...

## Macro Definition Documentation

## ◆ PW_REMOTE_PROP_PROTOCOL

#define PW_REMOTE_PROP_PROTOCOL "pipewire.protocol"

Specify the name of the protocol to use, default is using the native protocol.

Referenced by pw_remote_new().

## ◆ PW_REMOTE_PROP_REMOTE_NAME

#define PW_REMOTE_PROP_REMOTE_NAME "pipewire.remote.name"

The name of the remote to connect to, default env(PIPEWIRE_REMOTE) or pipewire-0.

## ◆ PW_VERSION_REMOTE_EVENTS

#define PW_VERSION_REMOTE_EVENTS 0

## Enumeration Type Documentation

## ◆ pw_remote_state

enum pw_remote_state

The state of a pw_remote.

Enumerator
PW_REMOTE_STATE_ERROR | remote is in error
PW_REMOTE_STATE_UNCONNECTED | not connected
PW_REMOTE_STATE_CONNECTING | connecting to remote PipeWire
PW_REMOTE_STATE_CONNECTED | remote is connected and ready

## Function Documentation

## ◆ pw_remote_add_listener()

void pw_remote_add_listener | ( | struct pw_remote * | remote,
|  | struct spa_hook * | listener,
|  | const struct pw_remote_events * | events,
|  | void * | data
| ) |  |

Add listener for events.

## ◆ pw_remote_export()

struct pw_proxy* pw_remote_export | ( | struct pw_remote * | remote,
|  | struct pw_node * | node
| ) |  |

run a local node in a remote graph

## ◆ pw_remote_find_proxy()

struct pw_proxy* pw_remote_find_proxy | ( | struct pw_remote * | remote,
|  | uint32_t | id
| ) |  |

Get the proxy with the given id.

References pw_map::pw_map_lookup().

## ◆ pw_remote_get_core()

struct pw_core* pw_remote_get_core | ( | struct pw_remote * | remote | ) |

Get the core used to construct this remote.

## ◆ pw_remote_get_core_info()

const struct pw_core_info* pw_remote_get_core_info | ( | struct pw_remote * | remote | ) |

Get the remote core info, can only be called when connected.

## ◆ pw_remote_get_core_proxy()

struct pw_core_proxy* pw_remote_get_core_proxy | ( | struct pw_remote * | remote | ) |

Get the core proxy, can only be called when connected.

## ◆ pw_remote_get_properties()

const struct pw_properties* pw_remote_get_properties | ( | struct pw_remote * | remote | ) |

Get the remote properties.

## ◆ pw_remote_get_state()

enum pw_remote_state pw_remote_get_state | ( | struct pw_remote * | remote,
|  | const char ** | error
| ) |  |

Get the current state, error is set when state is PW_REMOTE_STATE_ERROR.

## ◆ pw_remote_get_user_data()

void* pw_remote_get_user_data | ( | struct pw_remote * | remote | ) |

Get the user_data.

The size was given in pw_remote_new

## ◆ pw_remote_steal_fd()

int pw_remote_steal_fd | ( | struct pw_remote * | remote | ) |

Steal the fd of the remote connection or < 0 on error.

The remote will be in the unconnected state after this call.

References pw_protocol_client_steal_fd, and pw_remote::pw_remote_disconnect().