14

Has any one been able to get OpenCV to directly play video from the RasPiCam board using python?

I've seen some projects involving workarounds, but what I'm interested in is being able to use the RasPiCam board with OpenCV as if it were a USB cam.

Ideally, I'd like to do something like this:

import cv2.cv as cv
capture = cv.CreateCameraCapture(-1) 
#some other code to actually display the video
asked May 23, 2014 at 1:57

2 Answers 2

11

You will be able to access to the raspi camera like other V4L2 device using :

sudo modprobe bcm2835-v4l2

uv4l --driver raspicam --auto-video_nr

answered Jun 1, 2014 at 20:27
1
  • 1
    Excellent. Exactly what I was looking for. Thanks so much. Commented Jun 1, 2014 at 21:15
0

If you like reading, this guys tutorial is pretty comprehensive. http://thinkrpi.wordpress.com/opencv-and-pi-camera-board/

answered May 23, 2014 at 2:39
2
  • I looked at that tutorial, but it seems to me like that is geared for using OpenCV with C, not python. It wasn't clear to me after reading it how the tutorial would be useful for using OpenCV with python. Commented May 23, 2014 at 3:22
  • Yeah my bad.. sorry clearly didn't read your Question probably :S Commented May 23, 2014 at 3:23

Your Answer

Draft saved
Draft discarded

Sign up or log in

Sign up using Google
Sign up using Email and Password

Post as a guest

Required, but never shown

Post as a guest

Required, but never shown

By clicking "Post Your Answer", you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.