iisu Developer Forum

HomeHomeiisu™ 2.xiisu™ 2.xiisu™ APIiisu™ APIRegarding coordinate systemRegarding coordinate system's origin
Previous
 
Next
New Post
11/16/2011 2:23 PM
 

Hello,
I am working with a C++ example.
I caliberated using the T stance mode with me standing at origin of the 3 axes as shown in scene setup. I wanted to know that if I move my hand horizontally from left to right, what would be the leftmost and the rightmost coordinates of my pointer so that I can map it to the screen coordinates. I assumed that I would get values between -1 and 1 for leftmost and rightmost ends. But I am getting vague results for the x coordinate when I used UI.Controller1.Pointer1Coordinates. I have the following question:

How the coordinate system works? what point is considered as origin? It is the center of the virtual scene? Or the origin of the 3 axes as shown in the scene setup? Because even though I stand at the origin of the 3 axes (which is not the center of the virtual scene), I am getting vague results.

 
New Post
11/16/2011 3:07 PM
 
Hi,

If you are tracking a user in iisu 3d space, the coordinate system is as follows:

X pointing right of the camera

Y pointing outward from the camera

Z pointing upward


After calibration, you can use the MC2W matrix to retrive rotation and translation. MC2W is the camera to World matrix, used to convert camera space into World space. UI coordinate space is seperate to that, as UI tracking is independent on the body tracking or a calibration.
UI gives you coordintes in the normalized space of the UI pointing box, so the value of the pointer coordinates should be between  [-1,1]. If you want to retrive a pointer position in the 3D space use UI.Controller#.Pointer1Position3D (vector3) ( and respective data for the second pointer if necessary) .

I hope it helps. If you need more explanation, let us know!
Best regards,
Zofia

 
New Post
11/19/2011 10:58 AM
 


Thank you for your inputs!! 

As you mentioned, we tried using the MC2W matrix to get the camera to World matrix and its inverse. But it is giving some linking error when we build it. I have following questions related to this: 

1. We have some program snippets in the developer guide related to plugins. There we have used:m_camToWorldMatrix =pkPluginsManager->registerDataHandle ("SCENE.MC2W");

Does the use of "SCENE.MC2W" requires only pluginmanager? Can't we directly register the data handle for this iisu data on IskDevice? 

2. We tried to create a DLL sample application as described in the plugin section of developer guide. But we are getting a linking error when we use the Matrix4 in the following statement: 

m_camToWorldMatrix =pkPluginsManager->registerDataHandle ("SCENE.MC2W"); 

The error is: >pluginClass.obj : error LNK2001: unresolved external symbol "public: static class iisu::Matrix4 const iisu::Matrix4::IDENTITY" (?IDENTITY@Matrix4@iisu@@2V12@B) 

1>C:\Test\Debug\Test.dll : fatal error LNK1120: 1 unresolved externals. 

We tried to use the registerDataHandle method for "SCENE.MC2W" with plugin manager as well the IskDevice but got the above error. Why we are getting errors for Matrix4?

 3. Also, in the plugin sample you have used "SCENE.MC2W". But under the section 6.3.2.3 Scene calibration API, this data is defined as "SCENE.Calibration.MC2W". Which is the correct value for this data? 

Thanks in advance!!

 
New Post
11/21/2011 9:29 AM
 
Hi,

there is no need to use plugin manager to be able to retrive MC2W matrix. The data is available within iisu
when using data registered via SCENE.Calibration.MC2W path, the type of data is Matrix4. 

Best regards,
Zofia
 
Previous
 
Next
HomeHomeiisu™ 2.xiisu™ 2.xiisu™ APIiisu™ APIRegarding coordinate systemRegarding coordinate system's origin