forums.naturalpoint.com

Discussion and Support for the OptiTrack, SmartNav and TrackIR brands by NaturalPoint

[C#] NPVector Member-Types (cast)

by Striezel » Fri Jul 16, 2010 9:01 am

Hello,
I'm new to OptiTrack and try to receive Trackingdata from a NPVector-Object. The Members X, Y, Z, Roll, Pitch and Yaw return an "object".

The values are needed as float in meters, yet a (float)-cast throws an exception.

To which Type do i need to convert these objects?
Is there a C#-Reference/Documentation available, that I didn't find?

Thanks a lot in advance!
Striezel
 
Posts: 7
Joined: Fri Jul 16, 2010 8:27 am

by Birch » Fri Jul 16, 2010 1:45 pm

Try double / VT_R8
Birch
NaturalPoint Employee
NaturalPoint Employee
 
Posts: 1139
Joined: Thu Jan 30, 2003 5:00 am
Location: Corvallis, Oregon

by Striezel » Fri Jul 16, 2010 3:12 pm

Thanks, its working. Couldnt find it in the samples or elsewhere. Should have thought of and tried that myself before...
Striezel
 
Posts: 7
Joined: Fri Jul 16, 2010 8:27 am


Return to OptiTrack SDK