tsdconseil / opencv-demonstrator

OpenCV demonstrator (GUI)
http://www.tsdconseil.fr/log/opencv/demo/index-en.html
GNU Lesser General Public License v3.0
141 stars 57 forks source link

Add IP camera input source #38

Closed valera-rozuvan closed 8 years ago

valera-rozuvan commented 8 years ago

OpenCV comes with support for IP Cameras out of the box (I believe this is the case if OpenCV was compiled with FFmpeg support). Since in our build instructions we include ffmpeg, we can provide an option to use an IP camera as video source. The user just has to provide a URL to the video source.

Please see this simple example of how to get frame-by-frame visuals from an IP camera: http://answers.opencv.org/question/58360/ip-camera-with-opencv-c/ .

PS: for your information, IP cameras utilize the RTSP protocol. This protocol is supported by many video players, such as VLC media player.

@juliena82 What do you think?

applemuncy commented 8 years ago

This is good to know. Perhaps the test-webcan.exe should be changed to test that the URL of the IP camera is correct and working.

juliena82 commented 8 years ago

Actually, I think (but not recently tested on this version of software) that IP camera are already supported! In fact, the API is the same as when you read a video file. Only instead of specifying a file path, you provide a RTSP (for instance) url. I already used it, but on another project.

juliena82 commented 8 years ago

PS: the only limitation in the current GUI, is that it does not let you enter manually a URL / PATH. This is very easy to change...

juliena82 commented 8 years ago

I will add the option to specify manually the URL.

juliena82 commented 8 years ago

It would just need the option to specify manually the URL. But since this not an urgency, and as proposed in issue #36 , the way the inputs are selected will problably change soon, I propose to close this issue and add a remark about IP camera in issue #36

applemuncy commented 8 years ago

Yes, change in the GUI is what I meant : )

Yes, move to #36

valera-rozuvan commented 8 years ago

+1