CMSampleBuffer

extension CMSampleBuffer
  • Convert CMSampleBuffer to UIImage

    • orientation: The orientation of the resulting UIImage.
    • scale: The scale factor of the resulting UIImage.

    Declaration

    Swift

    func image(orientation: UIImage.Orientation = .up, scale: CGFloat = 1.0) -> UIImage?

    Return Value

    A UIImage object created from the CMSampleBuffer.