AVCaptureDeviceInput——sessionPreset参数(AVCaptureSessionPreset):在AVCaptureSession上设置输出格式(效果图设备为iPhone XS max)
AVCaptureSessionPresetPhoto——适用于高分辨率照片质量输出

AVCaptureSessionPresetHigh——适用于高质量视频和音频输出

AVCaptureSessionPresetMedium——适用于中等质量输出,适合通过WiFi共享的输出视频和音频比特率

AVCaptureSessionPresetLow——适用于低质量输出,实现适合通过3G共享的输出视频和音频比特率

AVCaptureSessionPreset320x240——适用于320x240视频输出(无)
AVCaptureSessionPreset352x288——适用于352x288视频输出

AVCaptureSessionPreset640x480——适用于640x480视频输出

AVCaptureSessionPreset960x540——适用于960x540视频输出(无)
AVCaptureSessionPreset1280x720——适用于1280x720视频输出

AVCaptureSessionPreset1920x1080——适用于1920x1080视频输出

AVCaptureSessionPreset3840x2160——适用于3840x2160(UHD 4K)视频输出

AVCaptureSessionPresetiFrame960x540——可生成960x540 Apple iFrame视频和音频内容。以使用AAC音频以~30 Mbits / sec的速度实现960x540质量的iFrame H.264视频。 以iFrame格式捕获的QuickTime影片最适合编辑应用程序

AVCaptureSessionPresetiFrame1280x720——可生成1280x720 Apple iFrame视频和音频内容。以使用AAC音频以~40 Mbits / sec的速度实现1280x720质量的iFrame H.264视频。 以iFrame格式捕获的QuickTime影片最适合编辑应用程序

AVCaptureSessionPresetInputPriority——指示会话输入的格式优先,此更改表明客户端选择的输入格式现在决定了输出端提供的服务质量等级。当客户端将会话预设设置为除AVCaptureSessionPresetInputPriority以外的任何其他内容时,会话将继续负责配置输入和输出,并可根据需要随意更改其输入的activeFormat

网友评论