我开发了一个使用 android、python 和 opencv 的实时相机应用程序。应用程序因为这条指令 cv2.imshow("Frame", clone) 而崩溃。logcat 显示:
com.chaquo.python.PyException: error: OpenCV(3.4.2) /home/smith/git/chaquo/python/server/pypi/packages/opencv-python/build/3.4.2.16/cp36-cp36m-android_15_armeabi_v7a/src/opencv/modules/highgui/src/window.cpp:632: error: (-2: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 function 'cvShowImage'
当我将其替换为 plt.imshow(...,...) 然后 plt.show() 应用程序运行但不显示任何检测,因为 matplotlib.pyplot 并非旨在显示实时检测
有什么解决办法吗?