PDA

View Full Version : how to get image and show it in dialog



ni.jun
July 11, 2009, 16:53:35
VC++6.0
WINXP SP3
I want show image in dialog

in CYIXINPCBDlg.h ,I have add three "*.h"
#include "tisudshl.h"
#include "MemBuffer.h"
#include "smart_ptr.h"

then //A Grabber class is to be created as member of the dialog class

class CYIXINPCBDlg : public CDialog
{
public:
CYIXINPCBDlg(CWnd* pParent = NULL); // standard
DShowLib::Grabber m_cGrabber;

......
}

BOOL CYIXINPCBDlg::OnInitDialog()
{
......
m_cGrabber.openDev( "DFx 41AF02" );

if( m_cGrabber.isDevValid())
m_cGrabber.startLive();



but run this code .some worry hapened which shown in attach file

please help me thank you.

ni.jun
July 11, 2009, 17:02:11
shorry ! I foget add "ICFilterContainer.dll" .

But image can not be shown in dialog.

ni.jun
July 11, 2009, 17:16:52
I find video capture device has not been opened successfully, it is invalid.

m_cGrabber.openDev( "DFx 41AF02" );

if( m_cGrabber.isDevValid()) //?
m_cGrabber.startLive();