mirror of
https://gitlab.freedesktop.org/pipewire/pipewire.git
synced 2025-10-31 22:25:38 -04:00
pw_impl_port_new -> pw_context_create_port
This commit is contained in:
parent
930b595724
commit
2a142edadb
4 changed files with 14 additions and 11 deletions
|
|
@ -156,7 +156,7 @@ static struct pw_impl_port *get_port(struct pw_impl_node *node, enum spa_directi
|
|||
if (port_id == SPA_ID_INVALID)
|
||||
return NULL;
|
||||
|
||||
p = pw_impl_port_new(direction, port_id, NULL, 0);
|
||||
p = pw_context_create_port(node->context, direction, port_id, NULL, 0);
|
||||
if (p == NULL)
|
||||
return NULL;
|
||||
|
||||
|
|
|
|||
|
|
@ -1171,7 +1171,7 @@ static void node_port_info(void *data, enum spa_direction direction, uint32_t po
|
|||
pw_log_debug(NAME" %p: %s port %d added", node,
|
||||
pw_direction_as_string(direction), port_id);
|
||||
|
||||
if ((port = pw_impl_port_new(direction, port_id, info,
|
||||
if ((port = pw_context_create_port(node->context, direction, port_id, info,
|
||||
node->port_user_data_size))) {
|
||||
if ((res = pw_impl_port_add(port, node)) < 0) {
|
||||
pw_log_error(NAME" %p: can't add port %p: %d, %s",
|
||||
|
|
|
|||
|
|
@ -354,10 +354,12 @@ static void update_info(struct pw_impl_port *port, const struct spa_port_info *i
|
|||
}
|
||||
|
||||
SPA_EXPORT
|
||||
struct pw_impl_port *pw_impl_port_new(enum pw_direction direction,
|
||||
uint32_t port_id,
|
||||
const struct spa_port_info *info,
|
||||
size_t user_data_size)
|
||||
struct pw_impl_port *pw_context_create_port(
|
||||
struct pw_context *context,
|
||||
enum pw_direction direction,
|
||||
uint32_t port_id,
|
||||
const struct spa_port_info *info,
|
||||
size_t user_data_size)
|
||||
{
|
||||
struct impl *impl;
|
||||
struct pw_impl_port *this;
|
||||
|
|
|
|||
|
|
@ -905,17 +905,18 @@ int pw_context_recalc_graph(struct pw_context *context);
|
|||
/** Create a new port \memberof pw_impl_port
|
||||
* \return a newly allocated port */
|
||||
struct pw_impl_port *
|
||||
pw_impl_port_new(enum pw_direction direction,
|
||||
uint32_t port_id,
|
||||
const struct spa_port_info *info,
|
||||
size_t user_data_size);
|
||||
pw_context_create_port(struct pw_context *context,
|
||||
enum pw_direction direction,
|
||||
uint32_t port_id,
|
||||
const struct spa_port_info *info,
|
||||
size_t user_data_size);
|
||||
|
||||
void pw_impl_port_update_info(struct pw_impl_port *port, const struct spa_port_info *info);
|
||||
|
||||
int pw_impl_port_register(struct pw_impl_port *port,
|
||||
struct pw_properties *properties);
|
||||
|
||||
/** Get the user data of a port, the size of the memory was given \ref in pw_impl_port_new */
|
||||
/** Get the user data of a port, the size of the memory was given \ref in pw_context_create_port */
|
||||
void * pw_impl_port_get_user_data(struct pw_impl_port *port);
|
||||
|
||||
int pw_impl_port_set_mix(struct pw_impl_port *port, struct spa_node *node, uint32_t flags);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue