Hi guys, I have some trouble to run opencv app in imx8qxpc0mek. I am using kernel 4.14.98.2.3.0 and
DISTRO=fsl-imx-xwayland MACHINE=imx8qxpc0mek source fsl-setup-release.sh -b build-xwayland
$ bitbake fsl-image-validation-imx and add opencv package in /conf/local.conf : CORE_IMAGE_EXTRA_INSTALL += " opencv libopencv-core-dev libopencv-highgui-dev libopencv-imgproc-dev libopencv-objdetect-dev libopencv-ml-dev"
when I run opencv app, opencv app doesn't work and error is below: : terminate called after throwing an instance of 'cv::Exception' what(): OpenCV(4.0.1) /usr/src/debug/opencv/4.0.1.imx-r0/git/modules/highgui/src/window.cpp:610: error: (-2:Unspecified error) The function is not implemented. Rebuild the library with Windows, GTK+ 2.x or Cocoa 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'
I have checked /usr/lib/libopencv*.so and sdk as well. Should I add something to display appropriate opencv app or add some of packeges in yocto?
Hello yibhan,
Looks like you need the appropriate package to run opencv, Check this page from the community:
https://github.com/opencv/opencv/issues/8537
Regards
Hi guys,
Thank you for answering. It would be helpful and I have additional question.
I don't know what packages are suitable to add or do to fix my issue?
it would be problem for someone to run opencv app in imx8qxpmek.
I have added opencv packages based on default package, but opencv doesn't show window that means opencv can't connect UI backend package, so to fix my issue,
I don't have any idea what packages of yocto are needed to run opencv app appropriately.
Hello,
I you have one of our latest BSP, you don´t need to install an external package, Since it comes by default.
Regards
Hi Bio_TICFSL,
I have upgraded kernel version to 5.4.70-2.3.0 and opencv would be okay, but when I play video file(mp4 and avi) in opencv api func:
VideoCapture video ("chaplin.mp4");
video.read(frame); imshow(frame)
but, shown window is small and mp4 decoding doesn't work correctly
Is there any limitation on display media file in opencv in imx8qxp?
Hi Bio_TICFSL,
for your information, gtk-play is okay when mp4 file is played, but avi file doesn't work.
Hi Bio_TICFSL,
Thank you for answering. it would sound great.
I am gonna to use kernel 5.4.70.2.3.0.
Don't i need to apply an additional packages for opencv in kernel 5.4.70.2.3.0?
Please confirm my concern.
Thanks,
No, you don´t need external packages