Skip to content

Instantly share code, notes, and snippets.

@Ondra09
Created October 30, 2012 09:18
Show Gist options
  • Save Ondra09/3979197 to your computer and use it in GitHub Desktop.
Save Ondra09/3979197 to your computer and use it in GitHub Desktop.
OpenCV create iplImage header from buffer
CvSize size;
size.width = limitWidth;
size.height = limitHeight;
IplImage* lights_image_p;
lights_image_p = cvCreateImageHeader(size, IPL_DEPTH_8U, 1);
lights_image_p->imageData = (char*)scene.bmp.elems;
lights_image_p->imageDataOrigin = ipl_image_p->imageData;
cvShowImage("Fourrier", lights_image_p);
cvReleaseImageHeader(&lights_image_p);
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment