//////////////////////////////////////////resize//////////////////////////////////////
void m_resize(Mat& src, Mat &dst, int cols, int rows)
{
// if(src.cols==cols&&src.rows==rows){
// dst.create(cols,rows);
// src.convertTo(dst);
// return;
// }
// Mat aa( rows, cols, CV_8UC3, Scalar(0,255,0) );//其实是2*6的矩阵,因为每个元素有3个通道。
double scale_x = (double)src.cols / cols;
double scale_y = (double)src.rows / rows;
// dst.create(cols,rows);
uchar* dataDst = dst.data;
int stepDst = dst.step;
uchar* dataSrc = src.data;
int stepSrc = src.step;
int iWidthSrc = src.cols;
int iHiehgtSrc = src.rows;
for (int j = 0; j < dst.rows; ++j)
{
float fy = (float)((j +