First time here? Check out the FAQ!

Ask Your Question
0

How to capture video from an unknown camera?

asked Aug 11 '0

I have this new camera link text. I want to use the video/image from this camera to do some image processing functions. I have the program ready for a webcam (which is readily available on the internet) but since I'm new to OpenCV so I need your help in doing this. Thanks in advance.

The camera is connected to the system using a USB connector. Also, it has another connector which I use sometimes, which is a FireWire A serial bus connector. Also, the computer uses the software that is mentioned in the above link (ProgRes CapturePro for PC/MAC)

link text

Preview: (hide)

2 answers

Sort by » oldest newest most voted
0

answered Aug 13 '0

berak gravatar image

updated Aug 13 '0

i think, you should just try it out first, maybe even using python:

pip install opencv-python

then:

import cv2
cap = cv2.VideoCapture(0) # assuming usb connection
print(cap.isOpened())

if you get True you've already won !

if it's windows, also try :

cap = cv2.VideoCapture(0, cv2.CAP_DSHOW) # since MSMF is default

next attempt, firewire:

print(cv2.getBuildInformation())

there's a Video IO section, check DC1394 support there, if so:

cap = cv2.VideoCapture(0, cv2.CAP_DC1394) # assuming firewire connection

(if not, you could still try to rebuild opencv with resp. dc1394 libs locally, but that's another story...)

if all those fail, you should look into the SDK, that came with your cam (probably only usable from c++)

if you find any code, that looks like it's retrieving images, update your question, and we'll help you connecting it to opencv

Preview: (hide)
0

answered Aug 13 '0

palladin gravatar image

Check whether you can get video from the camera using ffmpeg. If Yes, you can capture video from the camera using ffmpeg and then convert the frames to cv:: Mat

Preview: (hide)

Question Tools

1 follower

Stats

Asked: Aug 11 '0

Seen: 2,130 times

Last updated: Aug 13 '20