10 #include "PlusConfigure.h" 16 using namespace DShowLib;
21 this->ICCapturingSourceNewFrameCallback = NULL;
36 if( pBitmap->getEnable() == true )
38 std::ostringstream ss;
39 ss << MediaSampleDesc.FrameNumber <<
" ";
40 pBitmap->drawText( RGB(255,0,0), 0, 0, ss.str().c_str() );
49 if (this->ICCapturingSourceNewFrameCallback != NULL)
52 (*ICCapturingSourceNewFrameCallback)( pBuffer->getPtr(), pBuffer->getBufferSize(), currFrame );
66 m_BufferWritten.resize( NumBuffers,
false );
74 if( currFrame < m_BufferWritten.size() )
76 std::ostringstream ss;
77 ss <<
"image" << currFrame <<
".bmp";
78 saveToFileBMP( *pBuffer, ss.str().c_str() );
79 m_BufferWritten.at( currFrame ) =
true;
void saveImage(smart_ptr< DShowLib::MemBuffer > pBuffer, DWORD currFrame)
void setBufferSize(unsigned long NumBuffers)
virtual void overlayCallback(DShowLib::Grabber &caller, smart_ptr< DShowLib::OverlayBitmap > pBitmap, const DShowLib::tsMediaSampleDesc &MediaSampleDesc)
virtual void frameReady(DShowLib::Grabber &caller, smart_ptr< DShowLib::MemBuffer > pBuffer, DWORD FrameNumber)