it's preferable to use OutputArrayOfArrays instead of vector<Mat>