Skip to content

Latest commit

 

History

History
26 lines (20 loc) · 1.1 KB

README.md

File metadata and controls

26 lines (20 loc) · 1.1 KB

MMVideoCapture

类似微信的拍照/摄像组件,短按拍照片,长按则进行视频拍摄。有对应的照片和视频的预览页面。

ScreenShot

Installation

pod "MMVideoCapture"

Usage

1st.

 let vc = MMCameraViewController.init(delegate: self)
 self.present(vc, animated: true, completion: nil)

2nd.

extension ViewController : MMCameraViewControllerDelegate{
    func cameraViewController(_ cameraViewController: MMCameraViewController, didFinishPick image: UIImage, asset: PHAsset) {
    
    }

    func cameraViewController(_ cameraViewController: MMCameraViewController, didFinishPickVideo url: URL, asset: PHAsset, coverImage: UIImage?) {
    
    }

    func cameraViewControllerDidDismiss(_ cameraViewController: MMCameraViewController) {
    
    }
}