Ask Your Question

Revision history [back]

click to hide/show revision 1
initial version

1) Include this header

#include <opencv2/imgcodecs/ios.h>

2) Use the OpenCV's "MatToUIImage(...)" to transform your Mat to an UIImage.

3) Save the UIImage using the standard methods. (Swift code, but you can figure out the Objective-C counterpart for it)

UIImageWriteToSavedPhotosAlbum(imageToSave, self, #selector(image(_:didFinishSavingWithError:contextInfo:)), nil)