#include <windows.h>
#include <stdio.h>
#include <conio.h>
#include <tchar.h>
#include <math.h>
//#include "vrpn_Tracker.h"

//#define WIACLIENT_TRACE_ON
#define USE_WIACLIENT


#ifdef USE_WIACLIENT
	#include "WIAClient_info.h"
    #include <pthread.h>
#endif
#include "WIAClientSM_info.h"


#ifdef TESTFUNCDLL_EXPORT
#define TESTFUNCDLL_API __declspec(dllexport) 
#else
#define TESTFUNCDLL_API __declspec(dllimport) 
#endif

extern "C" {
	TESTFUNCDLL_API int init_shared_memory();
	TESTFUNCDLL_API int create_shared_memory();
	TESTFUNCDLL_API int copy_data_to_shared_memory(const void *shared_data_aux, int size_shared_data);
	TESTFUNCDLL_API int stop_shared_memory();
	TESTFUNCDLL_API void reset_wiaclient_connected();
	TESTFUNCDLL_API void set_wiaclient_connected();
	TESTFUNCDLL_API bool is_wiaclient_connected();
	TESTFUNCDLL_API int get_jpg_length();
	TESTFUNCDLL_API BYTE * get_jpeg_data();
	TESTFUNCDLL_API long get_frame_id();
	TESTFUNCDLL_API int get_frame_sec( double *sec);
}