Skip to content

Instantly share code, notes, and snippets.

@luizventurote
Created February 3, 2018 19:15
Show Gist options
  • Save luizventurote/21830e6fbe5aea63bf1f796177ca65ed to your computer and use it in GitHub Desktop.
Save luizventurote/21830e6fbe5aea63bf1f796177ca65ed to your computer and use it in GitHub Desktop.
OpenCV Open Image
#include <iostream>
#include <stdio.h>
#include "opencv2/highgui/highgui.hpp"
int main( int argc, const char** argv ) {
IplImage* img = cvLoadImage( argv[1] );
cvNamedWindow("Example1", CV_WINDOW_AUTOSIZE);
cvShowImage("Example1", img);
cvWaitKey(0);
cvReleaseImage(&img);
cvDestroyWindow("Example1");
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment