Lenses are not perfect
All right. Our last bit is, is, is, I have, I have to break it to you that reality can be a problem. That's a nicer way of saying life sucks. In reality lenses aren't really thin, lenses aren't perfect, photographers aren't perfect, except some of us. Sensing arrays aren't perfect so sometimes we have to do stuff to try to fix these things.

So, here's an example of a problem that's fixable, easily, in mathematics and geometry. And this is referred to as geometric distortion. So on the left here, we have a nice, regular grid. But sometimes, our lenses are not perfect, and they'll bow things out like this, and this is called pin cushion distortion. And sometimes they'll bow things out like that, and that's referred to as barrel distortion.

By the way, for those of you that use Photoshop or other more sophisticated image manipulation tools. You can correct for this in the image, and in fact, in Photoshop and, and in Camera Raw, if it knows the camera and lens that you're using, you tell it, correct for the geometric aberrations and it will go ahead and just fix that for you. because it knows about the lens and it knows about the camera. By the way, I used the word, aberration.

That's what we tend to use for any sorts of problems that are, are in how the lenses, how the images are created. Here's an example of the correcting of that radial distortions. Radial coming out from the middle. Picture on the left taken with a lens that's actually designed to try to capture as much of the scene as possible, but it's very distorted. On the right, you can see the recovery making it as if everything were perfectly flat. Another kind of aberration or problem in computational photography is what's called chromatic aberration. Oh sure, if any of you are Pink Floyd fans, you're familiar with the picture that shows white light coming through a prism spreading out and making a rainbow. I would it to you, but I'm sure I'd have to pay Pink Floyd money. All right. And the problem is, is that different color lights are diffracted different amounts by a particular lens, or a particular medium. So the problem is, how do I get all the light coming from a point to land on the same place in my image?

And this is shown here where they're showing you the, the red and blue lights as converging to different places. And, here's an example at a corner, and when you blow it up, you can see this red line that's between the, the blue sky and the, the white building. Where did that red line come from, there's no red there. Well, that's chromatic aberration. By the way, Photoshop knows how to take care of that too. That one's a little bit more of an approximation,

but you can remove the chromatic aberration of your lenses that way. Last one we'll talk about is what's called vignetting. If you use certain cameras at certain aperture settings. Not all of the rays that are hitting from, say, the middle of the image, coming through the middle are being caught at the corners. So here we have a, a lens imaging system and we're going to talk about that in just a minute, and we've got some point. And the ones that would be near the edges goes, goes through a couple different lenses. Only some of them hit the imaging medium, and so what that causes is that you get these dark areas around the, the edges. And that's called vignetting.