mirror of
				https://gitlab.freedesktop.org/pipewire/pipewire.git
				synced 2025-11-03 09:01:54 -05:00 
			
		
		
		
	update for type changes
This commit is contained in:
		
							parent
							
								
									4c7fd98479
								
							
						
					
					
						commit
						5fb984a647
					
				
					 3 changed files with 12 additions and 12 deletions
				
			
		| 
						 | 
				
			
			@ -100,7 +100,7 @@ static int set_mask(pa_context *c, struct global *g)
 | 
			
		|||
{
 | 
			
		||||
	const char *str;
 | 
			
		||||
 | 
			
		||||
	if (g->type == PW_ID_INTERFACE_Node) {
 | 
			
		||||
	if (g->type == PW_TYPE_INTERFACE_Node) {
 | 
			
		||||
		if (g->props == NULL)
 | 
			
		||||
			return 0;
 | 
			
		||||
		if ((str = pw_properties_get(g->props, "media.class")) == NULL)
 | 
			
		||||
| 
						 | 
				
			
			@ -137,18 +137,18 @@ static int set_mask(pa_context *c, struct global *g)
 | 
			
		|||
			g->event = PA_SUBSCRIPTION_EVENT_SOURCE_OUTPUT;
 | 
			
		||||
		}
 | 
			
		||||
	}
 | 
			
		||||
	else if (g->type == PW_ID_INTERFACE_Module) {
 | 
			
		||||
	else if (g->type == PW_TYPE_INTERFACE_Module) {
 | 
			
		||||
		g->mask = PA_SUBSCRIPTION_MASK_MODULE;
 | 
			
		||||
		g->event = PA_SUBSCRIPTION_EVENT_MODULE;
 | 
			
		||||
	}
 | 
			
		||||
	else if (g->type == PW_ID_INTERFACE_Client) {
 | 
			
		||||
	else if (g->type == PW_TYPE_INTERFACE_Client) {
 | 
			
		||||
		g->mask = PA_SUBSCRIPTION_MASK_CLIENT;
 | 
			
		||||
		g->event = PA_SUBSCRIPTION_EVENT_CLIENT;
 | 
			
		||||
	}
 | 
			
		||||
	else if (g->type == PW_ID_INTERFACE_Port) {
 | 
			
		||||
	else if (g->type == PW_TYPE_INTERFACE_Port) {
 | 
			
		||||
		pw_log_debug("found port %d", g->id);
 | 
			
		||||
	}
 | 
			
		||||
	else if (g->type == PW_ID_INTERFACE_Link) {
 | 
			
		||||
	else if (g->type == PW_TYPE_INTERFACE_Link) {
 | 
			
		||||
                if ((str = pw_properties_get(g->props, "link.output")) == NULL)
 | 
			
		||||
			return 0;
 | 
			
		||||
		g->link_info.src = pa_context_find_global(c, pw_properties_parse_int(str));
 | 
			
		||||
| 
						 | 
				
			
			@ -262,7 +262,7 @@ static void remote_state_changed(void *data, enum pw_remote_state old,
 | 
			
		|||
 | 
			
		||||
		c->core_proxy = pw_remote_get_core_proxy(c->remote);
 | 
			
		||||
                c->registry_proxy = pw_core_proxy_get_registry(c->core_proxy,
 | 
			
		||||
							       PW_ID_INTERFACE_Registry,
 | 
			
		||||
							       PW_TYPE_INTERFACE_Registry,
 | 
			
		||||
                                                               PW_VERSION_REGISTRY, 0);
 | 
			
		||||
                pw_registry_proxy_add_listener(c->registry_proxy,
 | 
			
		||||
                                               &c->registry_listener,
 | 
			
		||||
| 
						 | 
				
			
			
 | 
			
		|||
| 
						 | 
				
			
			@ -71,17 +71,17 @@ static int ensure_global(pa_context *c, struct global *g)
 | 
			
		|||
	if (g->proxy != NULL)
 | 
			
		||||
		return 0;
 | 
			
		||||
 | 
			
		||||
	if (g->type == PW_ID_INTERFACE_Node) {
 | 
			
		||||
	if (g->type == PW_TYPE_INTERFACE_Node) {
 | 
			
		||||
		events = &node_events;
 | 
			
		||||
                client_version = PW_VERSION_NODE;
 | 
			
		||||
                destroy = (pw_destroy_t) pw_node_info_free;
 | 
			
		||||
	}
 | 
			
		||||
	else if (g->type == PW_ID_INTERFACE_Module) {
 | 
			
		||||
	else if (g->type == PW_TYPE_INTERFACE_Module) {
 | 
			
		||||
		events = &module_events;
 | 
			
		||||
                client_version = PW_VERSION_MODULE;
 | 
			
		||||
                destroy = (pw_destroy_t) pw_module_info_free;
 | 
			
		||||
	}
 | 
			
		||||
	else if (g->type == PW_ID_INTERFACE_Client) {
 | 
			
		||||
	else if (g->type == PW_TYPE_INTERFACE_Client) {
 | 
			
		||||
		events = &client_events;
 | 
			
		||||
                client_version = PW_VERSION_CLIENT;
 | 
			
		||||
                destroy = (pw_destroy_t) pw_client_info_free;
 | 
			
		||||
| 
						 | 
				
			
			
 | 
			
		|||
| 
						 | 
				
			
			@ -110,7 +110,7 @@ static struct global *find_linked(pa_stream *s, uint32_t idx)
 | 
			
		|||
	pa_context *c = s->context;
 | 
			
		||||
 | 
			
		||||
	spa_list_for_each(g, &c->globals, link) {
 | 
			
		||||
		if (g->type != PW_ID_INTERFACE_Link)
 | 
			
		||||
		if (g->type != PW_TYPE_INTERFACE_Link)
 | 
			
		||||
			continue;
 | 
			
		||||
 | 
			
		||||
		pw_log_debug("%d %d %d", idx,
 | 
			
		||||
| 
						 | 
				
			
			@ -209,7 +209,7 @@ static const struct spa_pod *get_buffers_param(pa_stream *s, pa_buffer_attr *att
 | 
			
		|||
			size, buffers);
 | 
			
		||||
 | 
			
		||||
	param = spa_pod_builder_object(b,
 | 
			
		||||
	                SPA_PARAM_Buffers, SPA_ID_OBJECT_ParamBuffers,
 | 
			
		||||
	                SPA_TYPE_OBJECT_ParamBuffers, SPA_PARAM_Buffers,
 | 
			
		||||
			":", SPA_PARAM_BUFFERS_buffers, "iru", buffers,
 | 
			
		||||
					SPA_POD_PROP_MIN_MAX(3, MAX_BUFFERS),
 | 
			
		||||
			":", SPA_PARAM_BUFFERS_blocks,  "i", blocks,
 | 
			
		||||
| 
						 | 
				
			
			@ -656,7 +656,7 @@ static const struct spa_pod *get_param(pa_stream *s, pa_sample_spec *ss, pa_chan
 | 
			
		|||
{
 | 
			
		||||
	const struct spa_pod *param;
 | 
			
		||||
	param = spa_pod_builder_object(b,
 | 
			
		||||
	                SPA_PARAM_EnumFormat, SPA_ID_OBJECT_Format,
 | 
			
		||||
	                SPA_TYPE_OBJECT_Format, SPA_PARAM_EnumFormat,
 | 
			
		||||
	                "I", SPA_MEDIA_TYPE_audio,
 | 
			
		||||
	                "I", SPA_MEDIA_SUBTYPE_raw,
 | 
			
		||||
	                ":", SPA_FORMAT_AUDIO_format,     "I", format_pa2id(s, ss->format),
 | 
			
		||||
| 
						 | 
				
			
			
 | 
			
		|||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue