1 | initial version |
^^ ah, nicely spotted. indeed, you cannot reshape() a roi (without cloning).
@valentine, i got 2 other objections:
int m = images[0].rows / x; // y !!
int n = images[0].cols / y; // x !!
and:
for (int j = 0; j < images[i].rows - m; j += m) {
for (int k = 0; k < images[i].cols - n; k += n) {