PDA

View Full Version : Why pictue Like this ??



webmice
March 17, 2004, 18:58:24
I Create a function like this to save the live picture by double Click

{
m_pGrabber->setSinkType( DShowLib::FrameGrabberSink( DShowLib::FrameGrabberSink::tFrameGrabberMode::eSN AP, DShowLib::eRGB24) );

int size_buffer = m_pGrabber->getAcqSizeMaxX()
* m_pGrabber->getAcqSizeMaxY() * 3; //1 byte per pixel.
BYTE* pBuf[5];
for( int i = 0; i < 3; ++i )
{
pBuf[i] = new BYTE[size_buffer];
}
DShowLib::Grabber::tMemBufferCollectionPtr pMemBufferCollection = m_pGrabber->newMemBufferCollection( 5 );
m_pGrabber->setActiveMemBufferCollection( pMemBufferCollection );
m_pGrabber->startLive( false );
m_pGrabber->snapImages( 3 );
m_pGrabber->stopLive();
pMemBufferCollection->save( "file*.bmp" );
AfxMessageBox ("Save OK");
}

Why the picture like this ?? blank

Stefan Geissler
March 18, 2004, 07:46:10
Hello webmice,

the first image that is delivered by the camera after startLive is disturbed. The is normal for this camera, therefore you can throw it away.

webmice
March 18, 2004, 13:18:40
I save five image all Same !!!

How can I capture Normal Picture from camera ????

Stefan Geissler
March 19, 2004, 10:28:25
As i wrote before in other , you could send your project to support at imagingcontrol dot com, so i could have a look on it.