【问题标题】:cvNamedWindow - function not implemented, unable to launch LibHandcvNamedWindow - 功能未实现,无法启动 LibHand
【发布时间】:2014-05-08 03:19:55
【问题描述】:

我想使用 LibHand 手势库,但我无法在 Ubuntu 13.10 上启动它。

我已经编译成功了(在克服了一些与链接器相关的问题之后),但是在运行pose_designer时,OpenCV库记录了GUI支持功能没有实现,指示我安装libgtk2.0-dev和pkg-config .但是,在安装这些包并重建 OpenCV 库后,问题仍然存在。受到具有类似 OpenCV 问题的人的 SO 帖子 (OpenCV error: the function is not implemented) 的启发,我切换到了 libqt。不幸的是,问题仍然存在。

日志文件的摘录附在下面。出现此错误的原因可能是什么?

WARNING: the mesh 'hand.mesh' includes vertices with more than 4 bone
  assignments. The lowest weighted assignments beyond this limit have been
  removed, so your animation may look slightly different. To eliminate this,
  reduce the number of bone assignments per vertex on your mesh to 4.
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 cvNamedWindow, file /home/user/Downloads/opencv-2.4.8/modules/highgui
  /src/window.cpp, line 483
Exception: /home/user/Downloads/opencv-2.4.8/modules/highgui/src/window.cpp:483:
  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 cvNamedWindow

【问题讨论】:

    标签: c++ opencv libhand


    【解决方案1】:

    好吧,你必须回去重建opencv(highgui模块)。

    运行 cmake(或 cmake-gui)并调整设置,直到确认支持 gui:

      GUI: 
        QT:                          NO
        Win32 UI:                    YES
        OpenGL support:              NO
        VTK support:                 NO
    

    (嗯,这是为了赢,但你会有一个 GTK 条目应该是“打开”)

    【讨论】:

    • 确实,这才是真正的原因。据推测,与我的想法相反,我没有重新编译所有内容 - 当我这样做时,错误消失了。非常感谢您的建议!
    【解决方案2】:

    在解压目录中找到CMakeLists.txt,您可以在其中找到启用和禁用不同支持的选项。

    1. Windows WITH_VFW“包括视频以支持 Windows”
    2. Carbon WITH_CARBON "在 UI 中使用 Carbon 而不是 Cocoa"
    3. GTK+ 2.x WITH_GTK_2_X "使用 GTK 版本 2"

    【讨论】:

      猜你喜欢
      • 2017-04-25
      • 1970-01-01
      • 2021-12-12
      • 2021-04-28
      • 1970-01-01
      • 1970-01-01
      • 2018-12-15
      • 1970-01-01
      • 2019-03-16
      相关资源
      最近更新 更多