![]() |
OpenNI 1.5.4
|
OpenNI defines two types of coordinate systems:
Those two coordinate systems are defined as below:
Feature | Projective Coordinates | Real World Coordinates |
---|---|---|
X-Y Units | pixels | millimeters |
Z Units | millimeters | millimeters |
X-Y Origin | upper-left corner of the FOV | center of FOV |
Z Origin | sensor's plane | sensor's plane |
X Direction | left to right | left to right |
Y Direction | top to bottom | bottom to top |
Z Direction | away from sensor | away from sensor |
A main difference between the two is that in projective coordinates, a real-world object (person, chair) gets bigger (in pixels) as it gets closer to the sensor, whereas its real-world size remains the same.
A depth generator creates the depth value of each pixel. By knowing the distance of the object and some geometrical information about the sensor (like its FOV), translation can be made between the two systems. see xn::DepthGenerator::ConvertProjectiveToRealWorld() and xn::DepthGenerator::ConvertRealWorldToProjective().