PDA

View Full Version : Win32 API Application



vzv55
May 13, 2010, 11:23:13
I need simple application written by API (C\C++ laguage)
where i can get live image.

I have Video Capture Device DMx 41AUC02(usb camera)
thank you very much!

Stefan Geissler
May 14, 2010, 10:00:20
Hello,

Please see the simple samples that come with IC Imaging Control. For example the "callback" is a simple Win32 console application.

vzv55
May 16, 2010, 11:30:04
Hello,

I send you my API project.
please help me what wrong with it?
a have an Unhandled exception(in debug mode)
after if(!m_Grabber.openDev( "DMx 41AUC02" ))

Unhandled exception at 0x1d22a35b in test.exe: 0xC0000005: Access violation reading location 0x1d22a35b.

if i run application - the window close without any message

in Debug folder i have
Dialogs_vc71d.dll
mfc71d.dll
msvcp71d.dll
msvcr71d.dll
TIS_DShowLib08d.dll
TIS_UDSHL08_vc71d.dll
Dialogs_vc71d.lib
TIS_UDSHL08_vc71d.lib
mjpeg_Debug_Win32.tca
dvdevice_Debug_Win32.vda
gigecam_Debug_Win32.vda
tisdcam_Debug_Win32.vda
uvc_driver_Debug_Win32.vda
vcc_vp_Debug_Win32.vda
in Release folder the same files without 'd'.

thank you



in addition i have all the time Unhandled exception in samples
in function showDevicePage.
only in sample DemoApp i have not problem!??

Windows XP Home Edition 2002 ,SP2, Microsoft Visual C++ .NET 2003 7.1.3088

Stefan Geissler
May 17, 2010, 11:05:21
Hello,

I am very sorry, but I was not able to reproduce your problem. Maybe this happened, because I changed some parts in the configuration. Also I moved the InitLibrary() and the setHWND() call to the WinMain() function, because these functions need only to be called once.

I changed the project configuration using the makros capabilities of Visual Studio. In the first step, I created an environment varialbe "IC31PATH". This varialbe contents the path to your IC Imaging Control 3.1. This is for example:

"c:\Documents and Settings\username\My Documents\IC Imaging Control 3.1"

"username" is your username. "My Documents" may is translated into your Windows using language.

Maybe you have to restart the computer after you have created this environment varialbe.

Now you can setup your project (which already have done in the attachment):
Open the project properties, select "All configurations", choose "C++" and enter in "Additional Include Directories " "$(IC31PATH)\classlib\include"
Then choose "Linker" and enter at "Output File" "$(IC31PATH)\classlib\$(PlatformName)\$(Configurati onName)/test.exe".
Enter at "Additional Library Directories" "$(IC31PATH)\classlib\$(PlatformName)\$(Configurati onName)". (Maybe "$(TargetDir)" will do the same job.

Now you have setup all configurations for debug and release, and if wanted also for 64 bit.

Please see the attached project for sample.

Also I would like you to remove the license key from InitLibrary next time you post a project.