Commit ad018da2 authored by Vadim Pisarevsky's avatar Vadim Pisarevsky

Merge pull request #3262 from StevenPuttemans:fix_window_param

parents 562ff9d1 90a1c6b1
...@@ -83,8 +83,8 @@ After checking that the image data was loaded correctly, we want to display our ...@@ -83,8 +83,8 @@ After checking that the image data was loaded correctly, we want to display our
.. container:: enumeratevisibleitemswithsquare .. container:: enumeratevisibleitemswithsquare
+ *CV_WINDOW_AUTOSIZE* is the only supported one if you do not use the Qt backend. In this case the window size will take up the size of the image it shows. No resize permitted! + *WINDOW_AUTOSIZE* is the only supported one if you do not use the Qt backend. In this case the window size will take up the size of the image it shows. No resize permitted!
+ *CV_WINDOW_NORMAL* on Qt you may use this to allow window resize. The image will resize itself according to the current window size. By using the | operator you also need to specify if you would like the image to keep its aspect ratio (*CV_WINDOW_KEEPRATIO*) or not (*CV_WINDOW_FREERATIO*). + *WINDOW_NORMAL* on Qt you may use this to allow window resize. The image will resize itself according to the current window size. By using the | operator you also need to specify if you would like the image to keep its aspect ratio (*WINDOW_KEEPRATIO*) or not (*WINDOW_FREERATIO*).
.. literalinclude:: ../../../../samples/cpp/tutorial_code/introduction/display_image/display_image.cpp .. literalinclude:: ../../../../samples/cpp/tutorial_code/introduction/display_image/display_image.cpp
:language: cpp :language: cpp
......
...@@ -46,7 +46,7 @@ Let's use a simple program such as DisplayImage.cpp shown below. ...@@ -46,7 +46,7 @@ Let's use a simple program such as DisplayImage.cpp shown below.
printf("No image data \n"); printf("No image data \n");
return -1; return -1;
} }
namedWindow("Display Image", CV_WINDOW_AUTOSIZE ); namedWindow("Display Image", WINDOW_AUTOSIZE );
imshow("Display Image", image); imshow("Display Image", image);
waitKey(0); waitKey(0);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment