mirror of
				https://gitlab.freedesktop.org/pipewire/pipewire.git
				synced 2025-11-03 09:01:54 -05:00 
			
		
		
		
	libcemara: take care of index offset when enumerating controls
Add an index offset when enumerating controls. We insert 2 properties before enumerating the controls so the index of the first control needs to have an offset of 2.
This commit is contained in:
		
							parent
							
								
									e387772dc2
								
							
						
					
					
						commit
						e5afc939e8
					
				
					 2 changed files with 4 additions and 4 deletions
				
			
		| 
						 | 
				
			
			@ -273,7 +273,7 @@ next:
 | 
			
		|||
		default:
 | 
			
		||||
			return spa_libcamera_enum_controls(impl,
 | 
			
		||||
					GET_OUT_PORT(impl, 0),
 | 
			
		||||
					seq, result.index - 2, num, filter);
 | 
			
		||||
					seq, result.index, 2, num, filter);
 | 
			
		||||
		}
 | 
			
		||||
		break;
 | 
			
		||||
	}
 | 
			
		||||
| 
						 | 
				
			
			@ -535,7 +535,7 @@ next:
 | 
			
		|||
 | 
			
		||||
	switch (id) {
 | 
			
		||||
	case SPA_PARAM_PropInfo:
 | 
			
		||||
		return spa_libcamera_enum_controls(impl, port, seq, start, num, filter);
 | 
			
		||||
		return spa_libcamera_enum_controls(impl, port, seq, start, 0, num, filter);
 | 
			
		||||
 | 
			
		||||
	case SPA_PARAM_EnumFormat:
 | 
			
		||||
		return spa_libcamera_enum_format(impl, port, seq, start, num, filter);
 | 
			
		||||
| 
						 | 
				
			
			
 | 
			
		|||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue