我在Ubuntu上安装了opencv。我正在尝试使用函数imshow()。它给出了一个错误
我已经在Ubuntu上安装了opencv。我正在尝试使用函数imshow()。这是一个错误,请找到下面的内容。我在Ubuntu上安装了opencv。我正在尝试使用函数imshow()。它给出了一个错误
OpenCV Error: Unspecified error (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 cvShowImage, file /io/opencv/modules/highgui/src/window.cpp, line 545
error Traceback (most recent call last) in() ----> 1 cv2.imshow('mask',img)
error: /io/opencv/modules/highgui/src/window.cpp:545: 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 cvShowImage
您可以尝试使用此选项中的cmake WITH_GTK=ON
OpenCV needs to be compiled with GTK support (WITH_GTK=ON).
_IF你在Ubuntu或Debian,请安装libgtk2.0-dev的和pkg配置,然后重新运行cmake或配置script_ – Miki
我已经alredy重新运行cmake仍然无法正常工作 –