美文网首页
iOS/macOS 视频采集(1)

iOS/macOS 视频采集(1)

作者: yxibng | 来源:发表于2021-04-02 16:41 被阅读0次

参考demo AppleVideoCapturer

核心类

AVCaptureSession

An object that manages capture activity and coordinates the flow of data from input devices to capture outputs.

AVCaptureDevice

A device that provides input (such as audio or video) for capture sessions and offers controls for hardware-specific capture features.

AVCaptureDeviceInput

A capture input that provides media from a capture device to a capture session.

AVCaptureVideoDataOutput

A capture output that records video and provides access to video frames for processing.

AVCaptureConnection

A connection between a specific pair of capture input and capture output objects in a capture session.

AVCaptureVideoPreviewLayer

A Core Animation layer that displays the video as it’s captured.

步骤

  1. 创建 captureSession
  2. 配置captureSession,添加Input和output
  3. 开始采集startRunning

相关文章

网友评论

      本文标题:iOS/macOS 视频采集(1)

      本文链接:https://www.haomeiwen.com/subject/btdqkltx.html