Skip to content

Commit

Permalink
Shorter indentation
Browse files Browse the repository at this point in the history
  • Loading branch information
xzzz9097 committed Jun 27, 2017
1 parent 641f16f commit dc37b93
Showing 1 changed file with 6 additions and 2 deletions.
8 changes: 6 additions & 2 deletions Machine/ViewController.swift
Original file line number Diff line number Diff line change
Expand Up @@ -76,7 +76,9 @@ class ViewController: NSViewController, AVCaptureVideoDataOutputSampleBufferDele
}
}

func captureOutput(_ output: AVCaptureOutput, didOutput sampleBuffer: CMSampleBuffer, from connection: AVCaptureConnection) {
func captureOutput(_ output: AVCaptureOutput,
didOutput sampleBuffer: CMSampleBuffer,
from connection: AVCaptureConnection) {
guard let pixelBuffer = CMSampleBufferGetImageBuffer(sampleBuffer) else {
return
}
Expand All @@ -88,7 +90,9 @@ class ViewController: NSViewController, AVCaptureVideoDataOutputSampleBufferDele
options: [:])

do {
try imageRequestHandler.perform([VNDetectFaceRectanglesRequest(completionHandler: handleRequestOutput)])
try imageRequestHandler.perform(
[VNDetectFaceRectanglesRequest(completionHandler: handleRequestOutput)]
)
} catch {
print(error)
}
Expand Down

0 comments on commit dc37b93

Please sign in to comment.