Each column of the picture links to a column one repeat to the side. Where the hidden surface is near, the two linked columns sit closer, so the eyes must meet in front of the wall. The page gives both columns the same colour, and the pair of eyes reads that as depth.
The constraint method with hidden-surface removal is after Thimbleby, Inglis and Witten (1994). The single-image random-dot stereogram came from the work of Christopher Tyler and Maureen Clarke. The history page tells how it came to be.