Sunday, April 10, 2011

ThreeDee

Yes. Even I have been caught up in the 3D craze that's sweeping across the entertainment world. To be precise, my interest is rather independent of the entire 3D gaming and movie industry - I have not watched avatar (the trailer I hear is necessary and sufficient). My interests lie largely in the plane of photography and nature, so I thought I'd do some stereoscopy.

I've been a fan of magiceye for a while. Ever since staring at one of their calendars over 10 years ago, I've wondered how those escheresque tilings of palm trees and waves could reveal hidden dolphins embedded in the third dimension. Was it like a hologram, was it trickery, or was it my imagination?

The idea of parallax lies at the heart of mid-range depth perception in humans. At shorter (ie less than ~ 1m) scales, the human eye lens focuses, giving an idea of depth. At longer (ie more than ~1km) scales, the only source of scale is familiar objects, such as a tree, a human, or a superintelligent amphibious squid.

The extreme ranges are well-covered in photography. A thin depth of field simulates the short-range focusing of the eye - this is why wedding photographers love 50 f/1.8 lenses. At longer ranges, we need familiar subjects in the distant landscape. This is more of a function of luck than skill. Not very many photographers can claim to have willingly inserted a superintelligent amphibious squid in their grand landscapes.

The middle range is even harder to control - usually photographers just stop down on their apertures, and throw depth perception into the depths. Here is where stereography comes into play. Tt simulates the parallax perception of the eye by taking two pictures from two angles, and then somehow tricking the brain into believing depth.

The first part is simple - just stand to one side. Take a shot. Move over by a couple of inches. Shoot again. Of course you have to keep aperture, focus, and central subject fixed, but that's trivial. The second part is remarkably difficult. The most familiar method is obviously the colored-glasses-method, or anaglyphs, that color the images separately, and use an incredibly ugly pair of glasses to channel the images into the desired eyes. At the other end of the spectrum, techniques today use different polarizations, interlacing, and/or really fast shuttering to do essentially the same thing.

I've tried two quick methods in my dear workspace. The first is lame. It's so lame, it's called 'wiggle.' The term is self-explanatory, and if you haven't caught the hint, here's an example from my workspace:


Photobucket

Admit it. That was lame. For a larger version and a more prolonged seizure, click on the image.

The second method has less jugglewuggle, but requires you to do something incredible. You need to cross your eyes, touch your nose to your elbow, and sing the Marseillase in a sea of chocolate mousse. No - it's just crossing your eyes until you see a third image in the middle. That one is the 3D version. It takes practice - and the method is well explained out here. Here's my workspace again:


Again, for gorgeous mind-blowing 3D, click on the image.

Trust me - it works - and I can see a sharp 3D image. If you can do it too, you're sending the left image (taken inches to the right) to the right eye, and vice versa.

In each case, you're encoding in the third dimension in one way or another, just like a hologram. The first one codes it into the time dimension, with the irritating loop providing the brain the third dimension information. The second one is more tricky - it codes it into the extra image - essentially, the larger 2D image contains the extra information. Similarly, the other methods use spatial (interlacing), temporal (shuttering), or even optical (polarization) dimensions to provide depth in a 2D image. Perhaps a challenge in current 3D technology is not only displaying 3D images, but also encoding the depth information without taking up much memory.

The truly interesting stuff is how the brain processes this stuff. A 3D image in Matlab looks like a three-dimensional array, with numbers sitting at specified row, column, and page numbers. How is it represented in the brain? Do we have arrays of information in our neurons? Or is it an ingeniously crafted sparse matrix, with only the locations of my eraser, chair, and giant invisible pot of gold stored with 3D data? It's not even 3D - probably 5D - if you include time and color. Yes, color is a dimension. For the answers, I need to read biology, and therein lies my brain aneurysm.


No comments:

Post a Comment