A method for registering a first imaging detector to a surface projects a sequence of k images toward the surface, wherein k≧4, wherein each of the k images has a pattern of lines that extend in a direction that is orthogonal to a movement direction. The pattern encodes an ordered sequence of labels, each label having k binary elements, such that, in the movement direction, any portion of the pattern that is k equal increments long encodes one label of the ordered sequence. The method obtains, for at least a first pixel in the first imaging detector, along at least one line that is parallel to the movement direction, a first sequence of k signal values indicative of the k binary elements of a first label from the ordered sequence of labels and correlates the at least the first pixel in the first imaging detector to the surface.