Mat.fromPtr constructor
this constructor is a wrapper of
Mat (int rows, int cols, int type, void *data, size_t step=AUTO_STEP)
https://docs.opencv.org/4.x/d3/d63/classcv_1_1Mat.html#a51615ebf17a64c968df0bf49b4de6a3a
Implementation
factory Mat.fromPtr(
ccore.Mat m,
int rows,
int cols,
int type,
int prows,
int pcols,
) {
final p = calloc<ccore.Mat>();
cvRun(() => ccore.Mat_FromPtr(m, rows, cols, type, prows, pcols, p));
final mat = Mat._(p);
return mat;
}