The CD drive shines a laser at the surface of the CD and can detect the reflective areas and the bumps by the amount of laser light they reflect. The drive converts the reflections into 1s and 0s to read digital data from the disc. See How CDs Work for more information.