Display images larger than screen resolution: scrollbar window ?

asked 2015-04-13 01:43:30 -0500

begueradj gravatar image

updated 2015-04-13 01:43:58 -0500

I am dealing with images larger than my screen resolution. When I read them with the flag cv2.WINDOW_AUTOSIZE I can not see the full image. However, I do not want to use cv2.WINDOW_NORMAL flag or the resize() function because I do not want to loose any information of my image.

Is there a way to show a large picture using OpenCV in its full size ? Ideally I wonder if there is a way to display a large image in a OpenCV window that can have a scroll bar in order to be able to scroll down the image and see it fully.

Thank you in advance for any hints

edit retag flag offensive close merge delete

Comments

1

There is no scrollbar based window, so people tend to split their image into regions of interest and loop over those to process them. Since OpenCV only has visualization tools for debugging, no one has put effort into creating decent visualization software. For that you would better use external libraries.

StevenPuttemans gravatar imageStevenPuttemans ( 2015-04-13 03:33:16 -0500 )edit

I know there is no such scrollbar in OpenCV windows, I just wonder if there is a possibility to modify its source code and where to have this behavior. My application will be a mess if I want to display images in a given library and process them in an other one.

begueradj gravatar imagebegueradj ( 2015-04-14 02:45:09 -0500 )edit

You would have to dig into the QT supported window functionality. If you built OpenCV with Qt support than scrollbars are possible, then you will have to write a modified window interface for that. And splitting visualisation and processing is no mess, that is just how decent programming is done. Use pure Qt for windowing instead of the OpenCV windows. That solves it all for you!

StevenPuttemans gravatar imageStevenPuttemans ( 2015-04-14 03:31:08 -0500 )edit