如何更改 OpenCV 应用程序中轨迹栏的位置? [英] How to change the position of the trackbar in OpenCV applications?

查看:47
本文介绍了如何更改 OpenCV 应用程序中轨迹栏的位置?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

通常在我的 OpenCV 项目中,在创建轨迹栏并将其放置在窗口中后,它会水平出现并位于窗口底部.

Usually in my OpenCV projects, after creating a trackbar and placing it in a window, it appears horizontally and at the bottom of the window.

是否可以更改轨迹栏的位置和方向?

推荐答案

遗憾的是没有cv::createTrackbar() 不允许更改轨迹栏的位置和方向.

Unfortunately no, cv::createTrackbar() doesn't allow changing the position and orientation of the trackbar.

但是如果您安装了 Qt,您可以创建自己的 GUI,使用您想要的轨迹栏(QSlider).你只需要学习cv::Mat转换成QImage

But if you have Qt installed you can create your own GUI, with the trackbar (QSlider) you want. You just need to learn to convert a cv::Mat into a QImage

这篇关于如何更改 OpenCV 应用程序中轨迹栏的位置?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆