jetcam icon indicating copy to clipboard operation
jetcam copied to clipboard

camera works on jupyter notebook, but not from terminal as file.py

Open carlosqro opened this issue 5 years ago • 1 comments

greetings

if I work with jupyter notebook I can use the camera, but if I try to run it from terminal as file.py I get the error:

[ WARN:0] global /home/nvidia/host/build_opencv/nv_opencv/modules/videoio/src/cap_gstreamer.cpp (933) open OpenCV | GStreamer warning: Cannot query video position: status=0, value=-1, duration=-1

right after: camera = USBCamera( capture_device=0 )

I tried:

gst-launch-1.0 v4l2src device=/dev/video0 ! videoconvert ! xvimagesink

and works OK

I use nanocamera example and get the same error:

[ WARN:0] global /home/nvidia/host/build_opencv/nv_opencv/modules/videoio/src/cap_gstreamer.cpp (933) open OpenCV | GStreamer warning: Cannot query video position: status=0, value=-1, duration=-1

but it open a video stream anyway and works OK

I am working with a logitech webcam 920

carlosqro avatar Apr 13 '20 00:04 carlosqro

Were you able to fix it? Did the NanoCamera work for you?

thehapyone avatar Jul 09 '20 11:07 thehapyone