Magic Eye

As a child I was fascinated from the “Magic Eye”-books and much later I was eager to figure out how this depth perception actually works. The result was a small Python-script which I used to “impress” my co-workers and my girlfriend in a nerdy way. ;-)

Obtaining Depth Perception

To obtain the depth perception, you have to squint your eyes in the “wall-eyed”-way (meaning that you have to focus behind the screen). The easiest way to achieve this is to make the picture about 30-40 cm wide on the screen, and then put your face close to it (a distance of 40 cm should work). Try to focus behind the screen to see the effect. If it does not work, get closer to the screen. As soon as you have the depth perception, you can slowly move back to a comfortable position. With a bit of training, it is easy to achieve depth perception from all distances.