mirror of
https://gitlab.freedesktop.org/pipewire/pipewire.git
synced 2025-11-04 13:30:12 -05:00
avoid including private.h
Expose some more methods to make it possible to build without including the private.h header, especially in modules.
This commit is contained in:
parent
8e6a5a1714
commit
df519ee3b3
43 changed files with 349 additions and 372 deletions
|
|
@ -26,15 +26,15 @@
|
|||
#include <stdbool.h>
|
||||
#include <string.h>
|
||||
|
||||
#include <spa/utils/result.h>
|
||||
#include <pipewire/impl.h>
|
||||
|
||||
#include <extensions/session-manager.h>
|
||||
|
||||
#include "client-endpoint.h"
|
||||
#include "endpoint.h"
|
||||
#include "endpoint-stream.h"
|
||||
|
||||
#include <pipewire/private.h>
|
||||
|
||||
#define NAME "client-endpoint"
|
||||
|
||||
struct factory_data {
|
||||
|
|
@ -184,8 +184,10 @@ static void *create_object(void *data,
|
|||
if (!properties)
|
||||
goto no_mem;
|
||||
|
||||
pw_properties_setf(properties, PW_KEY_CLIENT_ID, "%d", owner->global->id);
|
||||
pw_properties_setf(properties, PW_KEY_FACTORY_ID, "%d", factory->global->id);
|
||||
pw_properties_setf(properties, PW_KEY_CLIENT_ID, "%d",
|
||||
pw_impl_client_get_info(owner)->id);
|
||||
pw_properties_setf(properties, PW_KEY_FACTORY_ID, "%d",
|
||||
pw_impl_factory_get_info(factory)->id);
|
||||
|
||||
this->resource = pw_resource_new(owner, new_id, PW_PERM_RWX, type, version, 0);
|
||||
if (this->resource == NULL)
|
||||
|
|
@ -235,7 +237,7 @@ static void module_registered(void *data)
|
|||
char id[16];
|
||||
int res;
|
||||
|
||||
snprintf(id, sizeof(id), "%d", module->global->id);
|
||||
snprintf(id, sizeof(id), "%d", pw_impl_module_get_info(module)->id);
|
||||
items[0] = SPA_DICT_ITEM_INIT(PW_KEY_MODULE_ID, id);
|
||||
pw_impl_factory_update_properties(factory, &SPA_DICT_INIT(items, 1));
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue