PipeWire 0.2.6

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

Go to the source code of this file.

## Data Structures
struct | pw_port_events
| Port events, use pw_port_add_listener. More...

## Macros
#define | PW_TYPE__Port "PipeWire:Object:Port"
#define | PW_TYPE_PORT_BASE PW_TYPE__Port ":"
#define | PW_VERSION_PORT_EVENTS 0

## Enumerations
enum | pw_port_state { PW_PORT_STATE_ERROR = -1, PW_PORT_STATE_INIT = 0, PW_PORT_STATE_CONFIGURE = 1, PW_PORT_STATE_READY = 2, PW_PORT_STATE_PAUSED = 3, PW_PORT_STATE_STREAMING = 4 }

## Functions
enum pw_direction | pw_port_get_direction (struct pw_port *port)
| Get the port direction. More...
const struct pw_properties * | pw_port_get_properties (struct pw_port *port)
| Get the port properties. More...
int | pw_port_update_properties (struct pw_port *port, const struct spa_dict *dict)
| Update the port properties. More...
uint32_t | pw_port_get_id (struct pw_port *port)
| Get the port id. More...
struct pw_node * | pw_port_get_node (struct pw_port *port)
| Get the port parent node or NULL when not yet set. More...
void | pw_port_add_listener (struct pw_port *port, struct spa_hook *listener, const struct pw_port_events *events, void *data)
| Add an event listener on the port. More...

## Macro Definition Documentation

## ◆ PW_TYPE__Port

#define PW_TYPE__Port "PipeWire:Object:Port"

## ◆ PW_TYPE_PORT_BASE

#define PW_TYPE_PORT_BASE PW_TYPE__Port ":"

## ◆ PW_VERSION_PORT_EVENTS

#define PW_VERSION_PORT_EVENTS 0

## Enumeration Type Documentation

## ◆ pw_port_state

enum pw_port_state

Enumerator
PW_PORT_STATE_ERROR | the port is in error
PW_PORT_STATE_INIT | the port is being created
PW_PORT_STATE_CONFIGURE | the port is ready for format negotiation
PW_PORT_STATE_READY | the port is ready for buffer allocation
PW_PORT_STATE_PAUSED | the port is paused
PW_PORT_STATE_STREAMING | the port is streaming

## Function Documentation

## ◆ pw_port_add_listener()

void pw_port_add_listener | ( | struct pw_port * | port,
|  | struct spa_hook * | listener,
|  | const struct pw_port_events * | events,
|  | void * | data
| ) |  |

Add an event listener on the port.

## ◆ pw_port_get_direction()

enum pw_direction pw_port_get_direction | ( | struct pw_port * | port | ) |

Get the port direction.

## ◆ pw_port_get_id()

uint32_t pw_port_get_id | ( | struct pw_port * | port | ) |

Get the port id.

## ◆ pw_port_get_node()

struct pw_node* pw_port_get_node | ( | struct pw_port * | port | ) |

Get the port parent node or NULL when not yet set.

## ◆ pw_port_get_properties()

const struct pw_properties* pw_port_get_properties | ( | struct pw_port * | port | ) |

Get the port properties.

## ◆ pw_port_update_properties()

int pw_port_update_properties | ( | struct pw_port * | port,
|  | const struct spa_dict * | dict
| ) |  |

Update the port properties.

References pw_log::pw_log_debug(), PW_PORT_CHANGE_MASK_PROPS, pw_port_resource_info, and pw_properties::pw_properties_set().

Referenced by pw_port_add().

Here is the caller graph for this function: