有没有办法检查 iOS 设备是否支持具体的 AVCaptureSessionPreset?我想设置 AVCaptureSession 的分辨率,但我不知道如何检查设备是否能够使用选定的分辨率捕获相机帧。
AVCaptureSession * _session;
NSString * _sessionPreset;
_sessionPreset = AVCaptureSessionPreset1920x1080;
// Here I would like to perform a check.
[_session setSessionPreset:_sessionPreset];