Tobi_H
June 3, 2008, 11:42:36
Hi,
I use the callback-sample to test my modifikation of an image.
Later I must find an blob in the picture from an ir-transmiter.
My backgroundfilter works.
But how can I easily modiy the callback-sample to snap images for an indefinite time ?
Here I add my filter :
void CListener::frameReady( Grabber& caller, smart_ptr<MemBuffer> pBuffer, DWORD currFrame)
{
std::cout << "Buffer " << currFrame << " processed in CListener::frameReady()." << std::endl;
//saveImage( pBuffer, currFrame+100 );
pBuffer = bgFilter.filterBackground(pBuffer); // here my filter
saveImage( pBuffer, currFrame ); // Do the buffer processing.
//::Sleep(250); // Simulate a time expensive processing.
}
I use the callback-sample to test my modifikation of an image.
Later I must find an blob in the picture from an ir-transmiter.
My backgroundfilter works.
But how can I easily modiy the callback-sample to snap images for an indefinite time ?
Here I add my filter :
void CListener::frameReady( Grabber& caller, smart_ptr<MemBuffer> pBuffer, DWORD currFrame)
{
std::cout << "Buffer " << currFrame << " processed in CListener::frameReady()." << std::endl;
//saveImage( pBuffer, currFrame+100 );
pBuffer = bgFilter.filterBackground(pBuffer); // here my filter
saveImage( pBuffer, currFrame ); // Do the buffer processing.
//::Sleep(250); // Simulate a time expensive processing.
}