Warning: file_get_contents(/data/phpspider/zhask/data//catemap/9/ios/103.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
使用AVFoundation在iOS中支持视频稳定_Ios_Objective C_Avfoundation_Video Capture - Fatal编程技术网

使用AVFoundation在iOS中支持视频稳定

使用AVFoundation在iOS中支持视频稳定,ios,objective-c,avfoundation,video-capture,Ios,Objective C,Avfoundation,Video Capture,我正在使用AVFoundation在我的iOS应用程序中录制视频。一切正常。我正在尝试在录制视频时启用视频稳定。这是我的密码 我有AVCaptureConnetion作为 @property(nonatomic, retain) AVCaptureConnection *videoConnection; 在可用时启用视频稳定的代码 self.videoConnection = [self.videoOutput connectionWithMediaType:AVMediaTypeVideo]

我正在使用AVFoundation在我的iOS应用程序中录制视频。一切正常。我正在尝试在录制视频时启用视频稳定。这是我的密码

我有AVCaptureConnetion作为

@property(nonatomic, retain) AVCaptureConnection *videoConnection;
在可用时启用视频稳定的代码

self.videoConnection = [self.videoOutput connectionWithMediaType:AVMediaTypeVideo];

if([self.videoConnection isVideoMirroringSupported] && self.videoDeviceType == VideoDeviceTypeFrontCamera)
{
    [self.videoConnection setVideoMirrored:YES];
    NSLog(@"Video mirroring supported");
}
else
    NSLog(@"Video Mirroring not supported");

if ([self.videoConnection isVideoStabilizationSupported])
{
    [self.videoConnection enablesVideoStabilizationWhenAvailable];
    NSLog(@"Video Stabilization supported");
}
else
    NSLog(@"!!! Video Stabilization NOT supported");
每次我运行代码时,我都会在Xcode控制台中得到下面的输出

支持视频镜像
!!! 不支持视频稳定功能

为什么每次都不支持视频稳定?我用iPodtouch 5G、iPad2和iPadMini在iOS6和iOS7上进行了检查

根据,
即使如此,也不支持所有源格式和视频分辨率。

在我的应用程序中,录制的视频资源是640*480和mp4格式。这是问题的根源吗?如果是,支持的分辨率和格式是什么?AppleDocs不提供支持的分辨率和格式列表


有人能告诉我这件事吗?提前感谢。

640x480不支持稳定。查看WWDC 2012中的第520课时(“相机拍摄中的新内容”)。