Ask Your Question
1

QVGA Modes for ASUS Xtion Pro

asked 2013-03-10 19:43:23 -0600

JJAF_26 gravatar image

Hi!

I have an ASUS Xtion Pro (no RGB) and I need to capture the depth frames in QVGA mode but I can't set the proper option in opencv. It's operational or only the vga mode? When I set capture.open( CV_CAP_OPENNI_ASUS ) it gave me segmentation fault. I had to set with capture.open( CV_CAP_OPENNI ) to get to work but only vga :S.

I have installed Opencv 2.4.4 (Ubuntu 12.10).

Thanks in advance, José Ferreira

edit retag flag offensive close merge delete

2 answers

Sort by » oldest newest most voted
1

answered 2013-03-11 03:01:38 -0600

rics gravatar image

Although unfortunately I have never used Asus Xtion checking the docs I think that you should open the device with CV_CAP_OPENNI and then you can set the CV_CAP_OPENNI_IMAGE_GENERATOR_OUTPUT_MODE capture property to CV_CAP_OPENNI_QVGA_30HZ or CV_CAP_OPENNI_QVGA_60HZ.

Check this highgui user guide and especially the example code in the end.

edit flag offensive delete link more

Comments

Hi! thanks for your answer. I actually tried that but the following message appeared "This image mode is not supported by the device, the default value (CV_CAP_OPENNI_SXGA_15HZ) will be used". I think this is because CV_CAP_OPENNI_IMAGE_GENERATOR_OUTPUT_MODE is for RGB and ASUS Xtion Pro doesn't have it. There is another way to set the depth resolution to 320x240 ?

Thanks in advance, José Ferreira

JJAF_26 gravatar imageJJAF_26 ( 2013-03-11 05:04:47 -0600 )edit

According to the latest source (https://github.com/Itseez/opencv/blob/master/modules/highgui/include/opencv2/highgui/highgui_c.h) you can the set CV_CAP_OPENNI_DEPTH_GENERATOR_BASELINE property for depth generators. Possible values are below like CV_CAP_OPENNI_DEPTH_MAP. I do not know how does it affect the image size. May be you can set CV_CAP_PROP_FRAME_WIDTH and HEIGHT to 320x240 directly.

rics gravatar imagerics ( 2013-03-11 05:42:54 -0600 )edit
0

answered 2013-03-16 07:48:35 -0600

JJAF_26 gravatar image

updated 2013-03-16 07:49:26 -0600

Hi!

Thanks rics for your help but CV_CAP_PROP_FRAME_WIDTH and HEIGHT are only for get, not set. I am trying put this thing to work for some time but without success. Opencv isn't prepared to receive xtion depth @ 320x240?

thanks in advance, José Ferreira

edit flag offensive delete link more

Question Tools

Stats

Asked: 2013-03-10 19:43:23 -0600

Seen: 670 times

Last updated: Mar 16 '13