PDA

View Full Version : read VCDProperties



nicetoshare
March 7, 2011, 04:32:18
I am a newbie. this might be a silly question, but still hope someone help me to understand how the things work.

I took "MembufferCollection" in IC Image Control 3.1 vc9 samples, and added
following lines to print out VCDPropertyItems

//////////////////////////////////////////////
tIVCDPropertyItemsPtr pItems = grabber.getAvailableVCDProperties();
if( pItems != 0 )
{
tVCDPropertyItemArray itemArray = pItems->getItems();
for( tVCDPropertyItemArray::const_iterator itItem = itemArray.begin(); itItem != itemArray.end(); ++itItem )
{
std::cerr << (*itItem)->getName().c_str() << std::endl;
}
}
//////////////////////////////////////////////
The itemArray is size of 7, but no strings are printed out. MembufferCollection still can get the 5 snapshots.

While in another sample "List VCDProperties" I can get all the things I want:
Brightness
Gamma
Gain
Exposure
Trigger
GPIOStrobe
Brightness

How come two samples show different results? The only thing in my mind is that "List VCDProperties" uses MFC DLL while "MembufferCollection" does not.

many thanks!

Stefan Geissler
March 7, 2011, 16:20:51
Hello,

Which camera model do you use? Did you also set a breakpoint at

std::cerr << (*itItem)->getName().c_str() << std::endl; and check the content of *itItem?

nicetoshare
March 7, 2011, 16:48:34
It is a DMK 21BU04.

I did set a breakpoint before the for loop, then used "step run" to check the values.

I also tried removing all the breakpoints but one right after the quoted code (in order to see the console stderr printouts). got the same results: no names printed out.

Stefan Geissler
March 11, 2011, 10:12:58
We checked the code you posted and it is working absolutely fine.

That means, you must do something else wrong. I wonder, wether you have a device opened, or if( pItems != 0 ) is true.

nicetoshare
March 13, 2011, 07:22:13
If you want, we can arrange a teamviewer or vnc session so that you can check the problem.

Stefan Geissler
March 15, 2011, 09:27:30
Hello

Please create a support case at http://www.imagingcontrol.com/en_US/support/case/

Then you can send me your complete project, so I can check it.