How large are Rigid Body tracking latencies?

hpcv
Posts: 58
Joined: Tue Oct 23, 2007 2:09 pm

Re: How large are Rigid Body tracking latencies?

Post by hpcv »

Going off on a tangent here, but since it's my own topic...

I can't get the RigidBody-Sample application to work. I've modified the main part to accurately measure FPS, so that it looks like the following:

Code: Select all

    int mFrameCounter=0;
    NPRESULT result;
    LARGE_INTEGER ticksPerSec, ticks, prevTicks;
    QueryPerformanceFrequency(&ticksPerSec);
    QueryPerformanceCounter(&prevTicks);
 
    while(!_kbhit())
    {
        result = RB_GetLatestFrame();

        if(result == NPRESULT_SUCCESS)
        {
            QueryPerformanceCounter(&ticks);
            double fps = (double)ticksPerSec.QuadPart / (ticks.QuadPart - prevTicks.QuadPart);

            mFrameCounter++;


            int markers = RB_FrameMarkerCount();
            int bodies  = 0;

            for(int i=0; i<RB_GetRigidBodyCount(); i++)
                if(RB_IsRigidBodyTracked(i))
                    bodies++;

            if((mFrameCounter%32)==0)
                printf("Frame %5d   %.1ffps   Markers %3d   Tracked RB's  %2d\n", mFrameCounter, fps, markers, bodies);

                    prevTicks = ticks;

		} else {
                    printf("Error %d: %s\n", result, RB_GetResultString(result));
		}
        Sleep(1);
    }
However, when I run this it spits out a lot of:

Code: Select all

Error 11: Invalid license
RB_LoadProfile does not return an error value; it is only in RB_GetLatestFrame that the invalid license error occurs.

Yet, the Rigid Body Tool works fine and is able to track rigid bodies without licensing problems. Apparently this sample app does something differently.

How do I fix this?
beckdo
Posts: 520
Joined: Tue Jan 02, 2007 2:02 pm

Re: How large are Rigid Body tracking latencies?

Post by beckdo »

Upgrade the the latest OptiTrack SDK and the latest Tracking Toolkits. Then use the license tool to relicense yourself. We made some improvements to the license system recently when we launched Arena.
hpcv
Posts: 58
Joined: Tue Oct 23, 2007 2:09 pm

Re: How large are Rigid Body tracking latencies?

Post by hpcv »

I just did... I think. Twice. I'll uninstall everything first and start from scratch, then. Thanks!
hpcv
Posts: 58
Joined: Tue Oct 23, 2007 2:09 pm

Re: How large are Rigid Body tracking latencies?

Post by hpcv »

Just did a complete uninstall of all OptiTrack software -- c:\Program Files\NaturalPoint only contained some directories with examples that I'd extracted to there manually. I left them in place. I did, however, remove c:\Program Files\NaturalPoint\OptiTrack\License\ and its contents.

Then I downloaded fresh installers of the latest OptiTrack SDK (1.1.033 Final B) and Tracking Toolkits (1.0.033) and installed them in the default locations.

Then I reran the License Tool; the keys and other information were still in the text boxes (cached in the registry?), so I simply hit Activate and it reported success.

Then I tested the Rigid Body Tool, which worked, and was able to track rigid bodies in real time.

Then cleaned up the Visual Studio build of the RigidBody-Sample and completely removed the Debug output directory, including both NP*.dll files. Then did a complete rebuild.

But still RB_GetLatestFrame() returns 11:

Code: Select all

Error 11: License invalid
Apart from a complete system reinstall, I'm really out of options here. :( What to do?
beckdo
Posts: 520
Joined: Tue Jan 02, 2007 2:02 pm

Re: How large are Rigid Body tracking latencies?

Post by beckdo »

Please email support@naturalpoint.com directly and email them your license file (located in c:\program files\naturalpoint\optitrack\license). I'll help make sure you get up and running as soon as possible. Sorry for the inconvenience.
hpcv
Posts: 58
Joined: Tue Oct 23, 2007 2:09 pm

Re: How large are Rigid Body tracking latencies?

Post by hpcv »

Well, after solving the license problems, I got the RigidBody-Sample application to run. At full speed! No frame drops!

So I suppose there is something in the Rigid Body Tool that makes it slow. The 3D display rendering perhaps?
Post Reply