how to build OpenCV with UI backend? in raspberry pi

asked 2018-07-03 06:57:08 -0500

I am getting below error,

Traceback (most recent call last): File "/home/pi/", line 44, in <module> cv2.destroyAllWindows() cv2.error: OpenCV(3.4.1) /home/pi/opencv-3.4.1/modules/highgui/src/window.cpp:630: error: (-2) The function is not implemented. Rebuild the library with Windows, GTK+ 2.x or Carbon support. If you are on Ubuntu or Debian, install libgtk2.0-dev and pkg-config, then re-run cmake or configure script in function cvDestroyAllWindows

edit retag flag offensive close merge delete


you'll have to build the whole thing from src, after installing gtk2 or qt dev packages, see here

unfortunately, this also means, that you have to build it on your device (slow), and cannot cross-compile.

berak gravatar imageberak ( 2018-07-03 08:26:45 -0500 )edit

after installing gtk2 or qt dev packages, I build again but still facing same issue. Followed the steps from the link provided.

Dbhargava gravatar imageDbhargava ( 2018-07-06 04:43:37 -0500 )edit