小编Abd*_*auf的帖子

视频合并在后台iOS中

任务:将传单图像合并到传单视频中.

案例:

  • 创建传单[添加表情图片/文字..等]
  • 制作视频

情况1

  • 按后退按钮[用户将转到传单屏幕的应用程序列表],在此期间我们正在合并flyerSnapShoot在flyerVideo.and 它完美的工作.
  • 去电话库,我们看到了更新的视频.

案例2

  • 按iPhone Home按钮,我正在做与上面相同但面临以下错误.

FAIL =错误域= AVFoundationErrorDomain代码= -11800"操作无法完成"UserInfo = 0x17266d40 {NSLocalizedDescription =操作无法完成,NSUnderlyingError = 0x172b3920"操作无法完成.(OSStatus错误-16980.) ",NSLocalizedFailureReason =发生未知错误(-16980)}

代码:

- (void)modifyVideo:(NSURL *)src destination:(NSURL *)dest crop:(CGRect)crop
              scale:(CGFloat)scale overlay:(UIImage *)image
         completion:(void (^)(NSInteger, NSError *))callback {

    // Get a pointer to the asset
    AVURLAsset* firstAsset = [AVURLAsset URLAssetWithURL:src options:nil];

    // Make an instance of avmutablecomposition so that we can edit this asset:
    AVMutableComposition* mixComposition = [AVMutableComposition composition];

    // Add tracks to this …
Run Code Online (Sandbox Code Playgroud)

iphone video objective-c video-processing ios

7
推荐指数
1
解决办法
1684
查看次数

标签 统计

ios ×1

iphone ×1

objective-c ×1

video ×1

video-processing ×1