title: OpenCV, Qt, imread, namedWindow, imshow does not work
body: <p>In the <code>.pro</code> file:</p>
  
  <pre><code>QT       += core
  
  QT       -= gui
  
  TARGET    = latihan_2
  CONFIG   += console
  CONFIG   -= app_bundle
  
  TEMPLATE = app
  
  SOURCES += main.cpp
  
  INCLUDEPATH += E:\OpenCV\OpenCV\opencv\build\include
  
  LIBS += E:\OpenCV\OpenCV\opencv\build\x86\mingw\lib\libopencv_core246.dll.a
  LIBS += E:\OpenCV\OpenCV\opencv\build\x86\mingw\lib\libopencv_highgui246.dll.a
  LIBS += E:\OpenCV\OpenCV\opencv\build\x86\mingw\lib\libopencv_imgproc246.dll.a
  LIBS += E:\OpenCV\OpenCV\opencv\build\x86\mingw\lib\libopencv_features2d246.dll.a
  LIBS += E:\OpenCV\OpenCV\opencv\build\x86\mingw\lib\libopencv_calib3d246.dll.a
  </code></pre>
  
  <p>In <code>main.cpp</code>:</p>
  
  <pre><code>#include &lt;opencv2/core/core.hpp&gt;
  #include &lt;opencv2/highgui/highgui.hpp&gt;
  
  using namespace cv;
  
  int main(){
      //read image
      Mat image = imread("img.jpg", 1);
      //create image window named "My image"
      namedWindow("My Image", CV_WINDOW_AUTOSIZE);
      //show the image on window
      imshow("My image", image);
      //wait key for 5000ms
      waitKey(5000);
      return 1;
      }
  </code></pre>
  
  <p>When I hit run, there is no error, but it only shows a black window named <code>qtcreator_process_stub.exe</code>.</p>
  
  <p>Why the "My image" window doesn't come out and shows the img.jpg?
  I use Qt creator 2.8.1, based on Qt 5.1.1, and openCV-2.4.6.0.</p>