Modules

U Camera

LATEST VERSION 3.0 (10.02.2012)

Description:

Very simple module based on OpenCV capture functions. It allowes for get image in UImage format for urbi functions or viewing by for ex. Gostai Lab.

This module cooperate with
UColorDetector http://www.urbiforge.org/index.php/Modules/UColorDetection
UObjectDetector http://www.urbiforge.org/index.php/Modules/UObjectDetection
UMoveDetector http://www.urbiforge.org/index.php/Modules/UMoveDetection
UFacetDetector http://www.urbiforge.org/index.php/Modules/UFacET


Requirement:

Urbi SDK 2.7.1 or higher
OpenCV 2.3.1
MS Visual Studio 2008 or higher for compilation from sources

Module functions:

UCamera.image; - acces to UImage, you can see image in Urbi console also
UCamera.notify; - if 1 camera capture new image after read image (def. 0)
UCamera.fps; - set max image refresh in fps (def. 100)
UCamera.flip; - rotate image (0 - 0 deg, 1 - 90 deg, 2 - 180 deg, 3 - 270 deg)
UCamera.GetWidth(); - returns image width in pixels
UCamera.GetHeight(); - returns image height in pixels
UCamera.GetImage(); - capture new image, use this function to manualy capture

How to use in urbiscript:
loadModule("UCamera");

// choose device 0
var Global.Cam=UCamera.new(0); 
var Global.width=Global.Cam.GetWidth();
var Global.height=Global.Cam.GetHeight();

// Get new frame every UImage access
Global.Cam.notify=1;

// Set max img fps
Global.Cam.fps=20;

// Acces to UImage variable
Global.Cam.image;

// Acces to UBinary variable (OpenCV IplImage format)
Global.Cam.image;
Download here:

Version 2.3
http://lirec.ict.pwr.wroc.pl/~jkedzier/urbi/ucamera30_for_opencv231.zip

You can download OpenCV2.3.1 compiled with Intel TBB libraries.
http://lirec.ict.pwr.wroc.pl/~jkedzier/urbi/OpenCV2.3.1.zip




WRUT

Options: