c++ - How to Convert Byte Array to IplImage using OpenCv? -


how convert byte array iplimage using opencv ?

is possible conversion here byte array iplimage using opencv ?

short as

uchar mybytes[]={1,255,0,4,1,4,76,43,45}; mat mymat(3,3,cv_8uc1,mybytes); 

or analytical

int nl= mymat.rows;  int nc= mymat.cols; (int j=0; j<nl; j++)  {     uchar* data= mymat.ptr<uchar>(j);     (int i=0; i<nc; i++)          data[i]= mybytes[j*i]; } 

Comments

Popular posts from this blog

Why does Ruby on Rails generate add a blank line to the end of a file? -

keyboard - Smiles and long press feature in Android -

node.js - Bad Request - node js ajax post -