A depth image can be used for detecting the presence of an object on any rectangular flat surface, such as a rectangular part of a wall, a table, or a floor. Coupled with a projector or a TV panel, it lets us create an interactive system, sensitive to hands or feet, which move near the surface without touching.
If you are using a projector for creating a surface, fix it and turn it on to obtain a picture on a wall, table, or floor. If you are using a TV panel, turn it on.
Direct the depth camera to see the whole picture from the projector or TV and fix the camera's position. There is no need to place the camera in a way that the whole image occupies exactly all of the camera's image frame, because at the next step, we will mark this area's corners and later use the marks for cropping.
Mark the corners of the surface on the color image for using these for cropping. In the following...