PipeWire  0.3.61

The device is an object that manages nodes. More...

Files

file  impl-device.h
 pipewire/impl-device.h
 

Data Structures

struct  pw_impl_device_events
 Device events, listen to them with pw_impl_device_add_listener. More...
 
struct  pw_impl_device
 

Macros

#define PW_VERSION_IMPL_DEVICE_EVENTS   0
 

Functions

struct pw_impl_devicepw_context_create_device (struct pw_context *context, struct pw_properties *properties, size_t user_data_size)
 
int pw_impl_device_register (struct pw_impl_device *device, struct pw_properties *properties)
 
void pw_impl_device_destroy (struct pw_impl_device *device)
 
void * pw_impl_device_get_user_data (struct pw_impl_device *device)
 
int pw_impl_device_set_implementation (struct pw_impl_device *device, struct spa_device *spa_device)
 Set the device implementation. More...
 
struct spa_devicepw_impl_device_get_implementation (struct pw_impl_device *device)
 Get the device implementation. More...
 
struct pw_globalpw_impl_device_get_global (struct pw_impl_device *device)
 Get the global of this device. More...
 
void pw_impl_device_add_listener (struct pw_impl_device *device, struct spa_hook *listener, const struct pw_impl_device_events *events, void *data)
 Add an event listener. More...
 
int pw_impl_device_update_properties (struct pw_impl_device *device, const struct spa_dict *dict)
 
const struct pw_propertiespw_impl_device_get_properties (struct pw_impl_device *device)
 
int pw_impl_device_for_each_param (struct pw_impl_device *device, int seq, uint32_t param_id, uint32_t index, uint32_t max, const struct spa_pod *filter, int(*callback)(void *data, int seq, uint32_t id, uint32_t index, uint32_t next, struct spa_pod *param), void *data)
 

Detailed Description

The device is an object that manages nodes.

It typically corresponds to a physical hardware device but it does not have to be.

The purpose of the device is to provide an interface to dynamically create/remove/configure the nodes it manages.

Macro Definition Documentation

◆ PW_VERSION_IMPL_DEVICE_EVENTS

#define PW_VERSION_IMPL_DEVICE_EVENTS   0

Function Documentation

◆ pw_context_create_device()

struct pw_impl_device* pw_context_create_device ( struct pw_context context,
struct pw_properties properties,
size_t  user_data_size 
)

◆ pw_impl_device_register()

int pw_impl_device_register ( struct pw_impl_device device,
struct pw_properties properties 
)

◆ pw_impl_device_destroy()

void pw_impl_device_destroy ( struct pw_impl_device device)

◆ pw_impl_device_get_user_data()

void* pw_impl_device_get_user_data ( struct pw_impl_device device)

◆ pw_impl_device_set_implementation()

int pw_impl_device_set_implementation ( struct pw_impl_device device,
struct spa_device spa_device 
)

Set the device implementation.

◆ pw_impl_device_get_implementation()

struct spa_device* pw_impl_device_get_implementation ( struct pw_impl_device device)

Get the device implementation.

Examples
export-spa-device.c.

◆ pw_impl_device_get_global()

struct pw_global* pw_impl_device_get_global ( struct pw_impl_device device)

Get the global of this device.

◆ pw_impl_device_add_listener()

void pw_impl_device_add_listener ( struct pw_impl_device device,
struct spa_hook listener,
const struct pw_impl_device_events events,
void *  data 
)

Add an event listener.

◆ pw_impl_device_update_properties()

int pw_impl_device_update_properties ( struct pw_impl_device device,
const struct spa_dict dict 
)

◆ pw_impl_device_get_properties()

const struct pw_properties* pw_impl_device_get_properties ( struct pw_impl_device device)

◆ pw_impl_device_for_each_param()

int pw_impl_device_for_each_param ( struct pw_impl_device device,
int  seq,
uint32_t  param_id,
uint32_t  index,
uint32_t  max,
const struct spa_pod filter,
int(*)(void *data, int seq, uint32_t id, uint32_t index, uint32_t next, struct spa_pod *param)  callback,
void *  data 
)