Ask Your Question

Revision history [back]

click to hide/show revision 1
initial version

Load a jpg image from memory

From an IP camera I've read in a jpg image to a buffer in memory. If I write this buffer to a file "picture.jpg", I can open it directly in Windows. I can also open the file with OpenCV: Mat image; image = imread("picture.jpg"); imshow("video", image);

Is there a way to directly pass the memory buffer to OpenCV? Casting it to InputArray ends in error.

Best regards, Peak