【发布时间】:2016-05-19 03:19:09
【问题描述】:
当我专门运行这段代码时,我不断收到这个错误:这可能是什么问题?我假设找不到视频的 URL,但如果是这种情况,那么为什么会发生这种情况?
错误复制图像:错误域=NSURLErrorDomain 代码=-1100“在此服务器上找不到请求的 URL。” UserInfo={NSLocalizedDescription=在此服务器上未找到请求的 URL。, NSUnderlyingError=0x161215860 {Error Domain=NSPOSIXErrorDomain Code=2 "No such file or directory"}} 复制图像时出错,没有要复制的先前帧
这是导致问题的代码的 sn-p:
isRecording = true
self.godDamnWebView.hidden = true
UIView.animateWithDuration(0.5, delay: 0.0, options: [.Repeat, .Autoreverse, .AllowUserInteraction], animations: { () -> () in
self.cameraButton.transform = CGAffineTransformMakeScale(0.5, 0.5)
}, completion: nil)
let outputPath = NSTemporaryDirectory() + "output.mov"
let outputFileURL = NSURL(fileURLWithPath: outputPath)
videoFileOutput?.startRecordingToOutputFileURL(outputFileURL, recordingDelegate: self)
【问题讨论】: