Using OpenGL in Qt for Processing Images

Utilizing the power of the GPU, and OpenGL in particular, for Computer Vision and Image Processing purposes has always been a favorite topic of mine. It’s quite easy to find many examples around (even among official Qt example projects) to deal with and learn more about this topic but I figured there are no clear and step by step examples for people who are absolutely new to it. This post aims to cover a number of topics, including the following, in a step by step and simple manner:

  • How to use QOffscreenSurface class for off-screen rendering using OpenGL
  • How to use QOpenGLFramebufferObject to create Frame Buffer objects
  • How to use Vertex Shaders to perform Geometric Image Transformations
  • How to use Fragment Shaders to perform Image Filtering and per-pixel operations
  • How to convert a texture to QImage
Continue reading “Using OpenGL in Qt for Processing Images”

Deploying Qt+OpenCV Applications on macOS

Qt provides an extremely simple mechanism for deploying applications on macOS, thanks to macdeployqt tool. Unfortunately, the same does not apply to Qt for macOS applications that reference 3rd party libraries such as OpenCV. In this post, I’ll describe the manual but simple process of adding 3rd party libraries into macOS Application packages in order to eliminate the need for installing those libraries on our target computers.

Continue reading “Deploying Qt+OpenCV Applications on macOS”

Qt Installer Framework – How to Run an Executable During Installation

Qt Installer Framework provides a simple way of creating cross-platform installers and setup files. Some of the questions that are asked quite a lot, but unfortunately are not as well-documented as they should be, is about the “Execute” method which is used to run executable files during installation. In this post I’ve tried to clarify a couple of points about it with a couple of simple examples.

Continue reading “Qt Installer Framework – How to Run an Executable During Installation”

Configuring Qt for Windows Projects to Use OpenCV 4.1.0

I usually build OpenCV with the BUILD_opencv_world option which makes it quite easy to configure my Qt projects and work fast. But when it comes to deploying OpenCV powered applications, I still prefer to use the modular and default OpenCV build in order to deploy only the required DLLs and end up with a smaller installer file size.

Continue reading “Configuring Qt for Windows Projects to Use OpenCV 4.1.0”

Implementing Minimize To Tray Functionality Using Qt/C++

I wanted to create my own personal stand-alone YouTube Player with Minimize to System Tray functionality. In other words I wanted it to be minimized to the System Tray when I closed it and displayed again when I clicked its icon in System Tray. I actually did it the other day and the whole thing led to this post. So, in this post I’ll describe How to use Qt/C++ to create your own YouTube Player with Minimize to Tray functionality in less than 10 minutes.

Continue reading “Implementing Minimize To Tray Functionality Using Qt/C++”

How to Use DPAPI with Qt Framework to Encrypt and Decrypt Data

When dealing with data encryption and decryption in Windows operating systems, probably one of the best choices is to use the Data Protection API. In this post I’ll be sharing two simple functions that can be used to encrypt and decrypt data (such as passwords, recovery keys and so on) that you want to store in an easy, quick and highly protected manner. Needless to say, these functions can be used with C++ and Qt Framework.

Continue reading “How to Use DPAPI with Qt Framework to Encrypt and Decrypt Data”

Adding External Libraries to Qt Projects

As simple as it sounds, most of the time it’s a hassle to add the required libraries to your Qt projects. You have to add the include path, the libraries and if you are aiming to have a cross-platform project, you need to account for Windows, macOS and Linux operating systems separately. Well, there are a couple a methods to simplify this a bit which I’ll describe in this tutorial.



Continue reading “Adding External Libraries to Qt Projects”