GStreamer: Error opening bin: no source element for URI "/dev/stdin"
for videoCapture("/dev/stdin") for input stream from pi using netcat
I am a beginner working on a project that requires input video from raspberrypi(live streaming) to my pc that runs on Ubuntu 16.04. I use netcat and raspivid to stream the video using the commands,
nc.traditional -l -p 9090|python3 inputvideo.py
on the pc and
raspivid-w 1280 -h 720 -fps 30 -t 999999 -o -|nc IPaddrofPC 9090
on the pi.
But I am able to receive and view the video streaming in mplayer.
Now I want to use the video for image processing in opencv using python 3.5. I used the following code,
> import cv2
> cap=cv2.videoCapture("/dev/stdin")
> print(cap.isOpened())
> while(cap.isOpened==True):
> ret, frame= cap.read()
> gray = cv2.cvtColor(frame, cv2.COLOR_BGR2GRAY)
> cv2.imshow('video',gray)
> if cv2.waitKey(1) & 0xFF == ord('q'):
> break
>
> cv2.destroyAllWindows()
I get the following error,
GStreamer-CRITICAL **:gst_element_make_from_uri:assertion 'gst_uri_is_valid (uri)' failed
GStreamer: Error opening bin: no source element for URI "/dev/stdin"
False
I couldn't find the solution. Please help. Any kind of help would be appreciated.
i'm not using any of this, but to my knowledge, you need a real gstreamer "cmd pipeline" for this, not just "/dev/stdin"
How do we do that? I am not aware of it
R u using webcam or picamera?
https://gstreamer.freedesktop.org/dat...
stereo picamera