In my app i create a movie file from an array of still images using AVAssetWriter, AVAssetWriterInput and AVAssetWriterInputPixelBufferAdaptor (There are a lot of threads describing how to do that). As the AVAssetWriterInput output settings AVVideoWidthKey and AVVideoHeightKey, i let the user choose a video resolution (1080p, 720p, 540p or 480p) which i then also use for the -pixelBufferFromCGImage: method.
Creating a video works well with all resolutions on my iPhone 5. However on my iPhone 3GS every resolution higher than 480p gives me no video output but i also get no error except when i use 1080p as resolution (in this case, the -pixelBufferFromCGImage: method returns NULL). It is ok to me that the 3Gs might never be able to export videos with higher resolution than 480p as well as the iPhone 4 might not be able to export 1080p videos.
However, my question is: how would i check which video resolutions the device can write and only offer these resolutions to the user?