PipeWire  0.2.0
global.h File Reference
Include dependency graph for global.h:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Data Structures

struct  pw_global_events
 Global events, use pw_global_add_listener. More...
 

Macros

#define PW_VERSION_GLOBAL_EVENTS   0
 

Functions

struct pw_globalpw_global_new (struct pw_core *core, uint32_t type, uint32_t version, struct pw_properties *properties, void *object)
 Create a new global object. More...
 
int pw_global_register (struct pw_global *global, struct pw_client *owner, struct pw_global *parent)
 Register a global object to the core registry. More...
 
void pw_global_add_listener (struct pw_global *global, struct spa_hook *listener, const struct pw_global_events *events, void *data)
 Add an event listener on the global. More...
 
uint32_t pw_global_get_permissions (struct pw_global *global, struct pw_client *client)
 Get the permissions of the global for a given client. More...
 
struct pw_corepw_global_get_core (struct pw_global *global)
 Get the core object of this global. More...
 
struct pw_clientpw_global_get_owner (struct pw_global *global)
 Get the owner of the global. More...
 
struct pw_globalpw_global_get_parent (struct pw_global *global)
 Get the parent of a global. More...
 
uint32_t pw_global_get_type (struct pw_global *global)
 Get the global type. More...
 
uint32_t pw_global_get_version (struct pw_global *global)
 Get the global version. More...
 
const struct pw_propertiespw_global_get_properties (struct pw_global *global)
 Get the global properties. More...
 
void * pw_global_get_object (struct pw_global *global)
 Get the object associated with the global. More...
 
uint32_t pw_global_get_id (struct pw_global *global)
 Get the unique id of the global. More...
 
int pw_global_bind (struct pw_global *global, struct pw_client *client, uint32_t permissions, uint32_t version, uint32_t id)
 Let a client bind to a global. More...
 
void pw_global_destroy (struct pw_global *global)
 Destroy a global. More...
 

Macro Definition Documentation

◆ PW_VERSION_GLOBAL_EVENTS

#define PW_VERSION_GLOBAL_EVENTS   0

Function Documentation

◆ pw_global_add_listener()

void pw_global_add_listener ( struct pw_global global,
struct spa_hook *  listener,
const struct pw_global_events events,
void *  data 
)

Add an event listener on the global.

Referenced by pw_client_register(), pw_core::pw_core_new(), pw_factory_register(), pw_link_register(), and pw_port_register().

◆ pw_global_bind()

int pw_global_bind ( struct pw_global global,
struct pw_client client,
uint32_t  permissions,
uint32_t  version,
uint32_t  id 
)

Let a client bind to a global.

◆ pw_global_destroy()

void pw_global_destroy ( struct pw_global global)

Destroy a global.

◆ pw_global_get_core()

struct pw_core* pw_global_get_core ( struct pw_global global)

Get the core object of this global.

◆ pw_global_get_id()

uint32_t pw_global_get_id ( struct pw_global global)

Get the unique id of the global.

◆ pw_global_get_object()

void* pw_global_get_object ( struct pw_global global)

Get the object associated with the global.

This depends on the type of the global

◆ pw_global_get_owner()

struct pw_client* pw_global_get_owner ( struct pw_global global)

Get the owner of the global.

This can be NULL when the core is owner

◆ pw_global_get_parent()

struct pw_global* pw_global_get_parent ( struct pw_global global)

Get the parent of a global.

◆ pw_global_get_permissions()

uint32_t pw_global_get_permissions ( struct pw_global global,
struct pw_client client 
)

◆ pw_global_get_properties()

const struct pw_properties* pw_global_get_properties ( struct pw_global global)

Get the global properties.

◆ pw_global_get_type()

uint32_t pw_global_get_type ( struct pw_global global)

Get the global type.

◆ pw_global_get_version()

uint32_t pw_global_get_version ( struct pw_global global)

Get the global version.

◆ pw_global_new()

struct pw_global* pw_global_new ( struct pw_core core,
uint32_t  type,
uint32_t  version,
struct pw_properties properties,
void *  object 
)

Create a new global object.

Parameters
corethe core
typethe interface type of the global
versionthe interface version of the global
propertiesextra properties
objectglobal object

◆ pw_global_register()

int pw_global_register ( struct pw_global global,
struct pw_client owner,
struct pw_global parent 
)

Register a global object to the core registry.