mirror of
				https://gitlab.freedesktop.org/pipewire/pipewire.git
				synced 2025-11-03 09:01:54 -05:00 
			
		
		
		
	audioconvert2: DSP mode without format gives no ports
This commit is contained in:
		
							parent
							
								
									d53311099f
								
							
						
					
					
						commit
						db2cbdf906
					
				
					 1 changed files with 8 additions and 7 deletions
				
			
		| 
						 | 
					@ -826,13 +826,14 @@ static int reconfigure_mode(struct impl *this, enum spa_param_port_config_mode m
 | 
				
			||||||
	switch (mode) {
 | 
						switch (mode) {
 | 
				
			||||||
	case SPA_PARAM_PORT_CONFIG_MODE_dsp:
 | 
						case SPA_PARAM_PORT_CONFIG_MODE_dsp:
 | 
				
			||||||
	{
 | 
						{
 | 
				
			||||||
		if (info == NULL)
 | 
							if (info) {
 | 
				
			||||||
			return -EINVAL;
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
			dir->n_ports = info->info.raw.channels;
 | 
								dir->n_ports = info->info.raw.channels;
 | 
				
			||||||
			dir->format = *info;
 | 
								dir->format = *info;
 | 
				
			||||||
			dir->format.info.raw.format = SPA_AUDIO_FORMAT_DSP_F32;
 | 
								dir->format.info.raw.format = SPA_AUDIO_FORMAT_DSP_F32;
 | 
				
			||||||
			dir->have_format = true;
 | 
								dir->have_format = true;
 | 
				
			||||||
 | 
							} else {
 | 
				
			||||||
 | 
								dir->n_ports = 0;
 | 
				
			||||||
 | 
							}
 | 
				
			||||||
 | 
					
 | 
				
			||||||
		if (this->monitor && direction == SPA_DIRECTION_INPUT)
 | 
							if (this->monitor && direction == SPA_DIRECTION_INPUT)
 | 
				
			||||||
			this->dir[SPA_DIRECTION_OUTPUT].n_ports = dir->n_ports + 1;
 | 
								this->dir[SPA_DIRECTION_OUTPUT].n_ports = dir->n_ports + 1;
 | 
				
			||||||
| 
						 | 
					
 | 
				
			||||||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue