Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

AVFoundationErrorDomain Code=-11832 "Cannot Open" #13

Open
estock opened this issue Mar 24, 2016 · 6 comments
Open

AVFoundationErrorDomain Code=-11832 "Cannot Open" #13

estock opened this issue Mar 24, 2016 · 6 comments

Comments

@estock
Copy link

estock commented Mar 24, 2016

I'm using GPUImage to process a video and then save it as a Mov file, once the video is processed, it saves correctly to my video library.

UISaveVideoAtPathToSavedPhotosAlbum (pathToMovie, self, @selector(video:didFinishSavingWithError:contextInfo:), NULL);

in the didFinishSavingWithError function take the video URL and try to run it through NSGIF

  • (void)video: (NSString *) videoPath didFinishSavingWithError: (NSError *) error contextInfo: (void *) contextInfo;

    NSURL *fileURL = [NSURL fileURLWithPath:videoPath];
    [NSGIF createGIFfromURL:fileURL withFrameCount:30 delayTime:.010 loopCount:0 completion:^(NSURL *GifURL) {
    NSLog(@"Finished generating GIF: %@", GifURL);
    }];

    if (error) {
    NSLog(@"Error Saving Video To Library: %@", error);
    // Do anything needed to handle the error or display it to the user
    } else {
    NSLog(@"Saved Video To Library:");
    }

}

However I constantly get the following error

Error copying image: Error Domain=AVFoundationErrorDomain Code=-11832 "Cannot Open" UserInfo={NSUnderlyingError=0x12750ed50 {Error Domain=NSOSStatusErrorDomain Code=-12431 "(null)"}, NSLocalizedFailureReason=This media cannot be used., NSLocalizedDescription=Cannot Open}
2016-03-24 16:06:37.191 PhotoBooth[1123:444110] Error copying image and no previous frames to duplicate

Any idea what is causing this?

@boshd
Copy link

boshd commented Jun 9, 2016

Were you able to solve this yet? Im having the same problem.

@sebyddd
Copy link
Member

sebyddd commented Oct 7, 2016

This definitely sounds like an issue with your source video. Can you put a breakpoint before attempting to convert it to GIF and check the actual video file?

@mrazam110
Copy link

same error .. Any solution ?

@z-br
Copy link

z-br commented Sep 2, 2017

Same error here as well, used to work until I upgraded to ios11, but might be code changes too I don't know.

@binbins
Copy link

binbins commented Oct 16, 2017

native video (iphone make) is OK when convert to gif, but my mov is created from a group
of images, it goes wrong at - (nullable CGImageRef)copyCGImageAtTime:(CMTime)requestedTime actualTime:(nullable CMTime *)actualTime error:(NSError * _Nullable * _Nullable)outError

@binbins
Copy link

binbins commented Oct 16, 2017

I compare their exif info, is different, maybe the problem

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

6 participants