Runtime Opencv HighGui Error- “HIGHGUI ERROR: V4L/V4L2: VIDIOC_S_CROP”. Opencv cross compiled. Host=64bit Ubuntu 12.04. Target=ARM-Cortex-A9

前端 未结 3 878
鱼传尺愫
鱼传尺愫 2020-12-30 07:47

I am a beginner at OpenCV and trying my best to get a simple application running on an embedded platform. I cross-compiled OpenCV 2.4.4 and built it WITH_GTK=ON, WIT

相关标签:
3条回答
  • 2020-12-30 08:17

    Opencv highgui error

    Have to reinstall opencv using cmake

    git clone https://github.com/Itseez/opencv.git
    cd ~/opencv 
    mkdir release 
    cd release 
    cmake -D CMAKE_BUILD_TYPE=RELEASE -D CMAKE_INSTALL_PREFIX=/usr/local -D WITH_IPP=OFF ..
    make -j4 sudo 
    make install
    export PYTHONPATH=$PYTHONPATH:/usr/local/lib/python2.7/site-packages
    
    0 讨论(0)
  • 2020-12-30 08:19

    After doing the cmake statement Verify whether the output of cmake includes the following text: V4L/V4L2: Using libv4l.

    If it is not there, then install v4l2ucp, v4l-utils and libv4l-dev from synaptic package manager. Then cmake and build again.

    This worked for me but I was using OpenCV with python bindings on Ubuntu 12.04.

    0 讨论(0)
  • 2020-12-30 08:25

    In order to cross compile you need to tell pkg-config to lookup the proper path (by default this will be your host config/.pc files!)

    From pkg-config website

    • searching directories listed in $PKG_CONFIG_PATH
    • when $PKG_CONFIG_LIBDIR is specified, it will override the compiled in default directory (e.g. /usr/lib/pkgconfig) and the PKG_CONFIG_PATH. Note that when specifying PKG_CONFIG_LIBDIR, pkg-config will completely ignore the content in PKG_CONFIG_PATH, even if the documentation states different things.
    0 讨论(0)
提交回复
热议问题