Error while streaming MJPEG video with RTSP protocol

classic Classic list List threaded Threaded
2 messages Options
Reply | Threaded
Open this post in threaded view
|

Error while streaming MJPEG video with RTSP protocol

HeroGian
Hello,
I want to stream a MJPEG video from my ethernet camera with OpenCV and
Gstreamer.
I have tried to open the stream with the following gstreamer pipeline:

std::string pipe(
                "rtspsrc location=rtsp://192.168.1.219:554/video.pro1 !
application/x-rtp,encoding-name=JPEG,payload=26 ! "
                "rtpjpegdepay ! jpegdec ! xvimagesink sync=false ! appsink"
        );
cv::VideoCapture cap(pipe, cv::CAP_GSTREAMER);

but the previous code returns me the following error:

OpenCV Error: Unspecified error (GStreamer: cannot find appsink in manual
pipeline
) in cvCaptureFromCAM_GStreamer, file
/home/nvidia/Documents/CameraTests/src/opencv-3.3.0/modules/videoio/src/cap_gstreamer.cpp,
line 796
VIDEOIO(cvCreateCapture_GStreamer (CV_CAP_GSTREAMER_FILE, filename)): raised
OpenCV exception:

/home/nvidia/Documents/CameraTests/src/opencv-3.3.0/modules/videoio/src/cap_gstreamer.cpp:796:
error: (-2) GStreamer: cannot find appsink in manual pipeline
 in function cvCaptureFromCAM_GStreamer

I managed to stream the the same RTSP source with H264 and H265 algorithms,
MJPEG is the only format that doesn't work, then I suppose that is a
gstreamer pipeline problem..

thanks



--
Sent from: http://gstreamer-devel.966125.n4.nabble.com/
_______________________________________________
gstreamer-devel mailing list
[hidden email]
https://lists.freedesktop.org/mailman/listinfo/gstreamer-devel
Reply | Threaded
Open this post in threaded view
|

Re: Error while streaming MJPEG video with RTSP protocol

filnet
You have one sink too many.
You should remove the ximagesink.


Le Lundi 6 novembre 2017 17h35, HeroGian <[hidden email]> a écrit :


Hello,
I want to stream a MJPEG video from my ethernet camera with OpenCV and
Gstreamer.
I have tried to open the stream with the following gstreamer pipeline:

std::string pipe(
                "rtspsrc location=rtsp://192.168.1.219:554/video.pro1 !
application/x-rtp,encoding-name=JPEG,payload=26 ! "
                "rtpjpegdepay ! jpegdec ! xvimagesink sync=false ! appsink"
        );
cv::VideoCapture cap(pipe, cv::CAP_GSTREAMER);

but the previous code returns me the following error:

OpenCV Error: Unspecified error (GStreamer: cannot find appsink in manual
pipeline
) in cvCaptureFromCAM_GStreamer, file
/home/nvidia/Documents/CameraTests/src/opencv-3.3.0/modules/videoio/src/cap_gstreamer.cpp,
line 796
VIDEOIO(cvCreateCapture_GStreamer (CV_CAP_GSTREAMER_FILE, filename)): raised
OpenCV exception:

/home/nvidia/Documents/CameraTests/src/opencv-3.3.0/modules/videoio/src/cap_gstreamer.cpp:796:
error: (-2) GStreamer: cannot find appsink in manual pipeline
in function cvCaptureFromCAM_GStreamer

I managed to stream the the same RTSP source with H264 and H265 algorithms,
MJPEG is the only format that doesn't work, then I suppose that is a
gstreamer pipeline problem..

thanks



--
_______________________________________________
gstreamer-devel mailing list



_______________________________________________
gstreamer-devel mailing list
[hidden email]
https://lists.freedesktop.org/mailman/listinfo/gstreamer-devel