I don’t think it will come as a surprise to anyone that the first step in achieving a sharper image is proper focus. And, to get proper focus, you have to play with the twisty part at the front of your camera (the lens), until your image is as sharp as you can get it. Now, if you have a line-scan camera, and you have been fiddling with the &%$#&@* twisty part for the last couple of hours, and your image is still blurry, then your TDI line-scan camera is probably upside down. But don’t worry; ‘TDI-can’t-focus-itice’ is a condition that affects 50% of machine vision professionals who use a TDI camera for the first time. In fact, I was once afflicted by that embarrassing condition myself. There’s hope, with just a few clicks you can learn more about the TDI camera and how to prevent your loved ones from falling victim to ‘TDI-can’t-focus-itice’ (see the ‘TDI explained’ link at the bottom).
Now, as promised, I am going to show you two different approaches to the same problem: increasing image sharpness. Both techniques require a convolution step, and, both techniques require a point-to-point operation (i.e. add or subtract one image from another). The first technique uses the good old high-pass spatial filter to isolate the high frequencies. Then, a portion of the high-frequency image is added back to the original. That way, we end up with boosted sharpness:
Cool eh!?! Now, the important thing to remember is that you have to scale the hi-pass version (make brighter and/or darker), when you add it to the original. Otherwise the end result may be too dark or too bright. But don’t worry if it doesn’t look right the first time, it usually takes some fiddling around before you end up with scaling values that are right for your application.
The other technique called ‘un-sharp-masking’, is a similar approach except, instead of adding high frequencies, we remove low frequencies. First, we create a lo-pass version of the original then, you fiddle with yer scaling and subtract the low-frequency image from the original:
As you can see, we almost end up with the same result. However, if you look real hard, you might notice that the un-sharp Doraimon (Doraimon minus lo-pass) seems a tiny bit less sharp than the hi-pass Doraimon. This is due to the fact that the un-sharp approach sharpens by removing blurriness, in effect, letting you to see sharpness that is already there. Whereas, the hi-pass way adds sharpness by adding more of the existing sharpness, back into the image. So what? You say. Well, it might not be a big deal to some, but this means that any noise that was present with the high frequencies (in the original image) has been increased right along with sharpness. No way!!! Way!
For more information on TDI, click here.