O'Reilly logo

Augmented Reality with Kinect by Rui Wang

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Aligning color with depth

The steps to implement the green screen have now changed because of the alignment problem of color and depth images. Instead of directly blending the depth and color images, we will first construct a new texture for storing remapped colors (and use the player index to subtract the background colors). Then we will display the new texture on screen, which can be treated as the result of background removal.

Generating a color image from depth

This time we will use an inbuilt Kinect API method to align the color data with depth and combine them again. Let's start now:

  1. Now we will have to traverse all pixels and save the color values where the player index is valid (for others, we set the color to total black). This requires ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required