Ask Your Question

Revision history [back]

click to hide/show revision 1
initial version

convert Mat CV_8UC4 to byte[] Android

Hi i try to convert a Mat to Byte then the inverse so here is the code

 frame = new Mat(height, width, CvType.CV_8UC4);
        // traitement ...
         byte[] data = = new byte[(int) ( *  frame.channels())];
            frame.get(0, 0, data); 
        // but data.length=0