Skip to content
Snippets Groups Projects
Commit dd4f9a82 authored by Andreas Pehrson's avatar Andreas Pehrson
Browse files

Bug 1817724 - [libwebrtc] Restore changes to RTCCameraVideoCapturer.m. r=webrtc-reviewers,ng

parent a4c00309
No related branches found
No related tags found
No related merge requests found
......@@ -186,7 +186,6 @@ const int64_t kNanosecondsPerSecond = 1000000000;
[self updateOrientation];
[self updateDeviceCaptureFormat:format fps:fps];
[self updateVideoDataOutputPixelFormat:format];
[_videoDataOutput setSampleBufferDelegate:self queue:self.frameQueue];
[self.captureSession startRunning];
[self.currentDevice unlockForConfiguration];
self.isRunning = YES;
......@@ -206,7 +205,6 @@ const int64_t kNanosecondsPerSecond = 1000000000;
for (AVCaptureDeviceInput *oldInput in [self.captureSession.inputs copy]) {
[self.captureSession removeInput:oldInput];
}
[_videoDataOutput setSampleBufferDelegate:nil queue:nil];
[self.captureSession stopRunning];
#if TARGET_OS_IPHONE
......@@ -217,11 +215,6 @@ const int64_t kNanosecondsPerSecond = 1000000000;
}
});
#endif
// Wait for any pending captureOutput tasks.
dispatch_sync(self.frameQueue, ^{
});
self.isRunning = NO;
if (completionHandler) {
completionHandler();
......@@ -471,6 +464,7 @@ const int64_t kNanosecondsPerSecond = 1000000000;
_outputPixelFormat = _preferredOutputPixelFormat;
videoDataOutput.videoSettings = @{(NSString *)kCVPixelBufferPixelFormatTypeKey : pixelFormat};
videoDataOutput.alwaysDiscardsLateVideoFrames = NO;
[videoDataOutput setSampleBufferDelegate:self queue:self.frameQueue];
_videoDataOutput = videoDataOutput;
}
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment