captureOutput function isn't called using setSampleBufferDelegate

后端 未结 6 1969
臣服心动
臣服心动 2021-02-19 03:57

I\'m starting to develop an iOS app and this is my first SO post. I\'m trying to implement a UI view which can show the preview video of the rear camera and process the captured

6条回答
  •  天命终不由人
    2021-02-19 04:16

    If previous answers cannot solve your problem for swift 4 and newer, correct the function name by add public can fix the problem.

    public func captureOutput(_ output: AVCaptureOutput, didOutput sampleBuffer: CMSampleBuffer, from connection: AVCaptureConnection) {}
    

提交回复
热议问题