Sometimes, calls to API function TT_update() throws an exception. Even though I wrap the call in a try/catch statement, the exception is not always caught. All info I get is
My code for connecting to the tracker, (which now takes 7 seconds to run) followsUnhandled exception at 0x12fde062 in MainProgram.exe: 0xC0000005: Access violation reading location 0x00000026.
Code: Select all
int Connect()
{
if(TT_Initialize() != NPRESULT_SUCCESS)
{return -1;}
while(TT_CameraCount()==0)
{
TT_Update();
Sleep(5);
}
if (TT_LoadProject("D:\\GUIs\\project.ttp") != NPRESULT_SUCCESS)
{return -2;}
if(TT_LoadTrackables("D:\\GUIs\\Trackables.tra") != NPRESULT_SUCCESS)
{return -3;}
return 1;
}
Thankful for help
Fredrik