Community
cancel
Showing results for 
Search instead for 
Did you mean: 
Blasutig__Robert
Beginner
775 Views

Failing to open RTSP camera

Jump to solution

Is it possible to use an RTSP camera with OpenCV included with OpenVINO R3?  In Python I'm using this:

cam = cv2.VideoCapture("rtsp://user:pass@192.168.1.10/rtsph264480p")

... which will fail to open.  On the other hand:

cam = cv2.VideoCapture(0)

...will succeed, using my laptop's built in webcam.

This failure to connect also occurs when using an example such as crossroad_camera_sample and specifying the RTSP device using the '-i' option.  The output looks as follows:

InferenceEngine:
        API version ............ 1.2
        Build .................. 13911
[ INFO ] Parsing input parameters
[ INFO ] Reading input
[ INFO:0] VIDEOIO: Enabled backends(6, sorted by priority): FFMPEG(1000); MSMF(990); DSHOW(980); VFW(970); CV_IMAGES(960); CV_MJPEG(950)
[ ERROR ] Cannot open input file or camera: rtsp://user:pass@192.168.1.10/rtsph264480p

I have also confirmed that when NOT using OpenCV included with OpenVINO, that accessing the RTSP camera with my default OpenCV (3.3) is just fine.

Any advice is appreciated.  Thanks.

0 Kudos
1 Solution
Maksim_S_Intel
Employee
775 Views

Did you download the FFmpeg library wrapper to OpenVINO? You can find a PowerShell script in the opencv directory.

View solution in original post

3 Replies
Severine_H_Intel
Employee
775 Views

Dear Robert, 

OpenVINO is working with RTSP stream, could you try only with rtsp://user:pass@192.168.1.10/ ? The rest of the address indicate some video format, I think it might be the cause of the issue. 

Best, 

Severine

Maksim_S_Intel
Employee
776 Views

Did you download the FFmpeg library wrapper to OpenVINO? You can find a PowerShell script in the opencv directory.

View solution in original post

Blasutig__Robert
Beginner
775 Views

Running the PowerShell script to get the FFmpeg wrapper is the solution!  I've confirmed by uninstalling/installing OpenVINO and breaking it again, and to confirm that the script solves the issue.  

Much appreciated.

Reply