I am working on a project with AVFoundation and am currently getting the following error:
Error Domain=AVFoundationErrorDomain Code=-11800 "The operation could not be completed" UserInfo=0x10021ee80 {NSUnderlyingError=0x10015cee0 "The operation couldn’t be completed. (OSStatus error -12500.)", NSLocalizedFailureReason=An unknown error occurred (-12500), NSLocalizedDescription=The operation could not be completed}
Both GetMacOSStatusErrorString and GetMacOSStatusCommentString do not return anything, and it is not documented in any header files from what I can tell.
To reproduce this error you can download https://github.com/RSully/interframe/archive/3f9eb52c51f4f5ac593c295fc05e7b2771483b18.zip (specific commit linked). The project expects 2 arguments: an input file (mp4) and an output file (m4v) that, if it worked, it would create.
In a nutshell, I am using AVAssetExportSession to write an AVMutableComposition with 3 AVMutableCompositionTracks and an AVMutableVideoComposition (which would composite those 3 tracks into 1 final video). The error occurs because of something I am doing in my composition's tracks or video composition's instructions, I can't quite tell which, and depending on what this error code means would tell me which direction to begin debugging further.
Edit: I have committed a simpler version of that section of code that still causes -12500. https://github.com/RSully/interframe/archive/02cae3d127c13e92992d77fa6c54b4ff8f67e394.zip
Edit: I have filed a bug report with Apple with the example project and error code. rdar://16619826
Response from DTS:
I've since learned that error -12500 is "SourceFrameMissing".