Search code examples
c++windowubuntu-14.04opencv3.0trackbar

OpenCV 3.0.0: How to display trackbar at top of window in Ubuntu 14.04


I am following this tutorial to make a draggable trackbar, but the trackbar only appears on the bottom of the window, and I cannot find an option to change that behavior. In the tutorial, they clearly show the trackbar at the top of the figure.

http://docs.opencv.org/doc/tutorials/highgui/trackbar/trackbar.html

I expect this may be an issue caused by the "figure viewer" Ubuntu uses, but is there any way I can get it to appear at the top?


Solution

  • You can't do that! OpenCV GUIs features are just for building fast prototypes. To build more advanced GUIs you need to use a 3rd party libraries like Qt.

    A while back I wrote this simple Qt/OpenCV application to load an image with OpenCV and display it on a QMainWindow. By the way, Qt's trackbar name is QSlider.