OpenCV -> UIImage
cv::Mat mat /* = ... */;
UIImage* image = [UIImage fromCvMat:mat];UIImage -> OpenCV
| /** | |
| Extension for UITableViewController or UIViewController as you prefer | |
| */ | |
| extension UITableViewController { | |
| func colorSection(_ tableView: UITableView, willDisplay cell: UITableViewCell, forRowAt indexPath: IndexPath) { | |
| let cornerRadius: CGFloat = 0.0 | |
| cell.backgroundColor = UIColor.clear | |
| let layer: CAShapeLayer = CAShapeLayer() | |
| let pathRef: CGMutablePath = CGMutablePath() | |
| //dx leading an trailing margins |
OpenCV -> UIImage
cv::Mat mat /* = ... */;
UIImage* image = [UIImage fromCvMat:mat];UIImage -> OpenCV