在1080x1440中显示预览;获得分辨率最高的照片(3024x4032),并在iPhone 8 Plus上使用代码获取质量:
capturePhotoOutput?.capturePhoto(with: configurePhotoSettings(), delegate: self)有照片设置:
private func configurePhotoSettings() -> AVCapturePhotoSettings {
let photoSettings = AVCapturePhotoSettings()
photoSettings.isHighResolutionPhotoEnabled = true
photoSettings.isAutoStillImageStabilizationEnabled = (capturePhotoOutput?.isStillImageStabilizationSupported)!
photoSettings.isAutoDualCameraFusionEnabled = (capturePhotoOutput?.isDualCameraFusionSupported)!
return photoSettings
}一个接一个地做这件事(比如顺序拍摄模式),每次预览都会冻结很短时间,即使我在didFinishProcessingPhoto中什么也不做。
寻找解决方案,使捕获顺利,也许在后台线程,但目前我被困..。
发布于 2019-05-15 07:00:26
预览挂起的原因被称为光学稳定。
在拍摄照片时,你只需要关掉它就可以顺利预览:
photoSettings.isAutoStillImageStabilizationEnabled = falsehttps://stackoverflow.com/questions/50740668
复制相似问题