Frame Grabber SDK (Windows-C) Developer Guide
printf("Press any key to exit.\n");
WaitForKeyPress();
return 0;
}
A.2 Acquire Images with Internal Buffers
The following sample codes show how to acquire images with internal buffers of the SDK.
#include <stdio.h>
#include <Windows.h>
#include <process.h>
#include <conio.h>
#include "MVFGControl.h"
#define BUFFER_NUMBER
#define FILE_NAME_LEN
#define SAVE_IMAGE_NUM
#define TIMEOUT
bool g_bExit = false;
3
// Number of requested buffers
256 // The maximum length of file name
10
// The maximum number of saved images
1000 // Timeout; unit: millisecond (ms)
// Stop acquisition
// Wait for key press.
void WaitForKeyPress(void)
{
while(!_kbhit())
{
Sleep(10);
}
_getch();
}
// Clear residual data from stdin
void ClearStdin(void)
{
char c = '\0';
while (1)
{
c = getchar();
if ('\n' == c || EOF == c)
{
break;
}
}
}
// Exception information callback function.
void ExceptionCb(MV_FG_EXCEPTION_TYPE enExceptionType, void* pUser)
{
switch(enExceptionType)
75
    "