Here's my code:
func captureOutput(_ output: AVCaptureOutput,
didOutput sampleBuffer: CMSampleBuffer,
from connection: AVCaptureConnection) {
guard CMSampleBufferDataIsReady(sampleBuffer) else { return }
// This is the delegate method for
// AVCaptureVideoDataOutputSampleBufferDelegate and
// AVCaptureAudioDataOutputSampleBufferDelegate
}
I'm trying to use Vision framework and draw a layer over eyes where I got the success. However I want to record the same.