jjzjj

appendPixelBuffer

全部标签

ios - 什么会导致 appendPixelBuffer 返回 false?

我的代码很简单,我正在拍摄图像并将其作为提取帧的视频的标题幻灯片。但出于某种原因,appendPixelBuffer一直返回false。所有框架都设置为1200x1200的精确高度/宽度。从AVAssetWritter返回的错误是:ErrorDomain=AVFoundationErrorDomainCode=-11823"CannotSave"UserInfo=0x10c5c4b40{NSUnderlyingError=0x113716cf0"Theoperationcouldn’tbecompleted.(OSStatuserror-12412.)",NSLocalizedReco

ios - AVAssetWriterInputPixelBufferAdaptor appendPixelBuffer :buffer withPresentationTime returning error NSURLErrorCannotCreateFile

我正在从一组图像创建一个视频文件。我能够在模拟器上创建视频文件,但是当我尝试在设备上运行相同的代码时,它会出现以下错误:NSURLErrorDomainCode=-3000"Cannotcreatefile"UserInfo=0x200be260{NSUnderlyingError=0x200bb030"Theoperationcouldn’tbecompleted.(OSStatuserror-12149.)",NSLocalizedDescription=Cannotcreatefile}我已经搜索了很多,但找不到任何东西。这是创建路径的代码。NSString*path=[NSHo

iphone - AVAssetWriterInputPixelBufferAdaptor appendPixelBuffer

我使用下面的代码将图像写入视频-(void)writeImagesToMovieAtPath:(NSString*)pathwithSize:(CGSize)size{NSLog(@"WriteStarted");NSError*error=nil;AVAssetWriter*videoWriter=[[AVAssetWriteralloc]initWithURL:[NSURLfileURLWithPath:path]fileType:AVFileTypeMPEG4error:&error];NSParameterAssert(videoWriter);NSDictionary*vid