This creates an image generator from an asset, from which we can extract a CGImage near an iframe of the video. We’ll create our own time using CMTimeMake, setting it to the very beginning here.

Then we’ll turn the CGImage into a more usable UIImage. Setting the appliesPreferredTrackTransform property to YES guarantees that the image is returned the correct way up, rather than rotated (which otherwise happens sometimes).

Method 2: Complex and Elaborate

Another way to extract a UIImage comes courtesy of memmons. The principle is the same as above, with additional error checks in place, and the option to specify an NSTimeInterval at which the image should be returned: