Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

VIDEOIO ERROR: V4L2: Pixel format of incoming image is unsupported by OpenCV #35

Closed
koen81 opened this issue May 21, 2019 · 1 comment
Closed

Comments

@koen81
Copy link

koen81 commented May 21, 2019

Dear Sir,

Have been trying to get your amazing project up and running on a Nvidea Jetson Nano, combined with a RPi Cam v2 (supported out of the box).

When trying to run the speed-cam.py I get the VIDEOIO ERROR: V4L2: Pixel format of incoming image is unsupported by OpenCV.

So have been researching the error.

Things I have checked:

v4l2-ctl -d /dev/video0 --list-formats
ioctl: VIDIOC_ENUM_FMT
Index : 0
Type : Video Capture
Pixel Format: 'RG10'
Name : 10-bit Bayer RGRG/GBGB

When testing the camera with GStreamer the camera is working correctly (appears under /dev/video0;

(Source: https://www.jetsonhacks.com/2019/04/02/jetson-nano-raspberry-pi-camera/)
gst-launch-1.0 nvarguscamerasrc ! 'video/x-raw(memory:NVMM),width=3820, height=2464, framerate=21/1, format=NV12' ! nvvidconv flip-method=0 ! 'video/x-raw,width=960, height=616' ! nvvidconv ! nvegltransform ! nveglglessink -e

So it appears that most probably I will have to build OpenCV with Gstreamer enabled:
(Source: https://devtalk.nvidia.com/default/topic/1001696/jetson-tx1/failed-to-open-tx1-on-board-camera/post/5117370/#5117370)

But then the question is do you consider supporting GStreamer Pipeline in your application?

Kind regards

Koen

@pageauc
Copy link
Owner

pageauc commented Aug 1, 2019

Sorry for the delay. I have no problems implementing gstreamer support in speed-camera. Hear is an example of receive code for opencv. https://stackoverflow.com/questions/51539706/convert-gstreamer-pipeline-to-opencv-in-python
Currently I don't have ip camera but could setup a gstreamer sender source using another RPI. Summer is a busy time. Let me know if you are still interested and would be willing to do some testing. Regards Claude ...

@pageauc pageauc closed this as completed Sep 26, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants