Mapping non discrete color space pixels to depth or camera space. RRS feed

  • General discussion

  • I need to map a non-discrete floating point ColorSpacePoint to depth or camera space without losing precision (i.e. no truncating or rounding). I am aware of CoordinateMapper.MapColorFrameToDepthSpace() but that function maps discrete color bitmap. I need something like MapColorSpacePointToDepthSpace() function similar to available MapDepthPointToColorSpace() that takes a single CameraSpacePoint as a parameter and returns a corresponding DepthSpacePoint. I don't see anything like that in the CoordinateMapper. Perhaps there's a way to use interpolation to achieve a non-discrete color pixel coordinate mapping?
    Wednesday, November 5, 2014 2:45 AM

All replies

  • Can you provide more information on the scenario? Given that there isn't a 1 to 1 mapping from color to depth given that a 2D color pixel can project back into the 3D space at various levels. This is why you sometimes see a duplicate as that color falls on objects further away. If you want to know where that color pixel maps to Depth, you need to iterate over the depth/color lookup table returned from the MapColorFrameToDepth/MapColorFrameToCamera function to find where those land. 

    Carmine Sirignano - MSFT

    Thursday, November 6, 2014 1:21 AM
  • Basically. I run some image processing on the color image, mostly because it's higher resolution than IR. As a result of this, I get a sub-pixel coordinates in the color space, which I want to map to camera or depth space without losing precision. I can see how this may not be possible because of discretization and differences in the resolution of color and IR sensors.
    • Edited by simfero Saturday, November 8, 2014 1:27 AM
    Thursday, November 6, 2014 8:32 PM
  • I am currently facing kind of the same problem (getting as precise 3d coordinates for sub pixel accurate positions in colorspace as possible). Have you found a solution or workaround in the meantime?

    Wednesday, April 22, 2015 3:35 PM