mirror of
				https://gitlab.freedesktop.org/pipewire/pipewire.git
				synced 2025-11-03 09:01:54 -05:00 
			
		
		
		
	spa: libcamera: source: set "corrupted" flag if applicable
If the libcamera `FrameMetadata` reports anything other than `FrameSuccess`,
then set `SPA_META_HEADER_FLAG_CORRUPTED`, notifying the application that
the frame may be unusable.
(cherry picked from commit 561a9d6ebb)
			
			
This commit is contained in:
		
							parent
							
								
									7414d948ad
								
							
						
					
					
						commit
						5f77c729c2
					
				
					 1 changed files with 2 additions and 0 deletions
				
			
		| 
						 | 
					@ -1222,6 +1222,8 @@ void impl::requestComplete(libcamera::Request *request)
 | 
				
			||||||
	}
 | 
						}
 | 
				
			||||||
	if (b->h) {
 | 
						if (b->h) {
 | 
				
			||||||
		b->h->flags = 0;
 | 
							b->h->flags = 0;
 | 
				
			||||||
 | 
							if (fmd.status != FrameMetadata::Status::FrameSuccess)
 | 
				
			||||||
 | 
								b->h->flags |= SPA_META_HEADER_FLAG_CORRUPTED;
 | 
				
			||||||
		b->h->offset = 0;
 | 
							b->h->offset = 0;
 | 
				
			||||||
		b->h->seq = fmd.sequence;
 | 
							b->h->seq = fmd.sequence;
 | 
				
			||||||
		b->h->pts = fmd.timestamp;
 | 
							b->h->pts = fmd.timestamp;
 | 
				
			||||||
| 
						 | 
					
 | 
				
			||||||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue