1. An input apparatus comprising: a first camera which captures a finger and generates a first image representing the finger; a second camera which is placed a prescribed distance away from the first camera, and which captures the finger and generates a second image representing the finger; a processor configured to: detect, from the first image, a finger region containing the finger and detects, from the finger region, a fingertip position corresponding to a fingertip of the finger; set a template containing the finger region; generate a plurality of sub-templates by dividing the template along a longitudinal direction of the finger region; obtain a region that best matches the template on the second image, and which divides the region into search regions equal in number to the sub-templates along the longitudinal direction of the finger region; perform template matching between a sub-template selected from among the plurality of sub-templates as containing the fingertip position and a corresponding one of the search regions to find a matching point on the second image that corresponds to the fingertip position on the first image; and compute the position of the fingertip of the finger in real space, based on the fingertip position on the first image and the matching point on the second image.