Log reason for dropped frame in RTCCameraVideoCapturer.
Bug: None Change-Id: Ie4a41382c9fbf38c102d3850877545881f6a3d21 Reviewed-on: https://webrtc-review.googlesource.com/c/116063 Commit-Queue: Kári Helgason <kthelgason@webrtc.org> Reviewed-by: Peter Hanspers <peterhanspers@webrtc.org> Cr-Commit-Position: refs/heads/master@{#26146}
This commit is contained in:
parent
77aedaee69
commit
73eb41fe9e
@ -287,7 +287,14 @@ const int64_t kNanosecondsPerSecond = 1000000000;
|
||||
- (void)captureOutput:(AVCaptureOutput *)captureOutput
|
||||
didDropSampleBuffer:(CMSampleBufferRef)sampleBuffer
|
||||
fromConnection:(AVCaptureConnection *)connection {
|
||||
RTCLogError(@"Dropped sample buffer.");
|
||||
#if TARGET_OS_IPHONE
|
||||
CFStringRef droppedReason =
|
||||
CMGetAttachment(sampleBuffer, kCMSampleBufferAttachmentKey_DroppedFrameReason, nil);
|
||||
#else
|
||||
// DroppedFrameReason unavailable on macOS.
|
||||
CFStringRef droppedReason = nil;
|
||||
#endif
|
||||
RTCLogError(@"Dropped sample buffer. Reason: %@", (__bridge NSString *)droppedReason);
|
||||
}
|
||||
|
||||
#pragma mark - AVCaptureSession notifications
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user