Introduction: Reduce Motion Blur Using the GIMP
This Instructable helps you reduce the effects of soft motion blur you get because of camera shake. This is an experimental method developed by me, so please try out and leave comments, preferably with images.
As is evident from the quality of the photograph I hereby present, I am not a Pro. Heck. I don't even come close to my 5th grade cousin.
But I am OK with my favourite photo editor GIMP. So I tried developing a technique similar to the Unsharp Mask filter. All out of trial and error, so I don't guaranty anything. I have noticed it only reduces soft motion blur. So take a backup of the images you try this on. You have been warned.
( I found that the steps apply much better to the following images :
So here goes nothing.
Select your camera shake affected photograph and move on to the next step.
Click on the images in the following steps for a full view. Instructables seems to be cropping off the images in thumbnails, sometimes the important sections.
Step 1: Measure the Blur.
Find a suitable item/part of your image where you can 'Measure' your motion blur. That is, the angle and length. For the uninitiated, GIMP has a Measure tool. Find it. It usually looks like a divider/compass from the geometry box.
Step 2: Triplicate the Layer.
We will need the top 2 to create a sort of difference between an even more blurred version of the image (next step) and the original. Then we remove this difference from the original to get a some-what better image.
Don't ask me exactly how I came up with this. It was a bit of looking in the code of "unsharp mask" filter and a lot of trial and error.
Step 3: Add Motion Blur.
Yes. We add motion blur. If you have a slow enough computer, or large enough image on which you have run "unsharp mask" filter, you might have noticed "Blurring" before "Masking". Yes. What we do here is somewhat the same. Instead of blurring equally on all directions, we do a motion blur. Because we want to remove the motion blur.
For people who did not catch the above, it is simple : We fight motion blur with more motion blur, kind of like fighting fire with fire. Now on to what we do in this step.
In step 1, we measured the motion blur. Use this to fill the parameters for filters>blur>motion blur. Make sure you do this for the top layer. You may have to add or subtract a multiple of 90 to create the right motion blur.
Experimenting is a nice productive time pass. Do it.
Step 4: Switch Top Layer Mode to Grain Extract.
Make sure you have selected the top layer in the layers dialog, and change it's mode to grain extract. Don't panic at the result. All is fine.
Step 5: Merge the Top 2 Layers or Move to Group.
If Older than Gimp-2.8:
- Merge the top layer with the 2nd layer. Use the steps in the image to achieve it.
If Gimp-2.8 or later:
- Create a new Layer Group, and move the 2 layers to the new group.
Step 6: "Grain Merge" the Resultant Layer or Layer Group.
If older than Gimp-2.8
- Set the layer blending mode of the resultant top layer to "Grain merge".
If Gimp-2.8 or later
- Set the layer blending mode of the Layer group to "Grain Merge"
Play with Colors>Levels and the opacity of the layer/layer group to your liking. After each unblurring, if more is left, repeat. The resulting image is a bit sharper than the original.
The effect depends on different qualities of blurring, both during the shoot and step 3.
Your mileage may vary. Inputs are very much welcome.
11 years ago on Introduction
I've found that adjusting the red and cyan (blue and green composite) channels separately with opposite motion blur angles renders a better image, much like a reverse anaglyph. You can do this in GIMP by going to the channels dialog, right-click the red channel, then click "Channel to Selection". Copy the selection and paste as a new layer. Duplicate it and add motion blur with an angle of -90 (270) to 90 degrees (right semi-circle), depending on the angle of incidence. Do the same thing as you would with the Grain modes. Now do the same with the Cyan channel. Select the red channel and invert it. Copy and paste as a new layer, then duplicate. This time, when you add motion blur, set the angle opposite of the red channel 90 to 270 degrees (left semi-circle). I suspect this won't matter so much with a vertically blurred image.
Reply 8 years ago on Introduction
That means your lens is not good (or you are abusing the zoom), and what you are seeing is "Chromatic Abberration" . Are you clicking an object in the shadow with the background being bighter sky?
6 years ago
This is awesome! It would make a great script also
7 years ago
I'd be grateful for any practical suggestion you may have for how I could improve a particular image (described below).
The image is a TIFF file (1053 x 1373 pixels) that was produced (several years ago by a relative, not by me) by scanning a very old photograph. The defect that I would like to eliminate is that the image actually comprises two distinct identical images, which are displaced diagonally by about 5 pixels (as measured by me using the GIMP measurement tool).
To me, the two images do not appear to result from continuous motion of the photographic apparatus (whether the camera or the enlarger). My guess is that the two images resulted from jolting of the photographic enlarger during the exposure of the print.
I have GIMP in Ubuntu on my computer. Nevertheless, I am not familiar with advanced photo editing software like GIMP or Photoshop. I have done some playing around with Photoshop when I had a Windows machine. However, I can follow specific instructions (though not instructions that skip steps, or assume familiarity with photo editing software and jargon, etc).
11 years ago on Introduction
this is awsome! i've only tried it out on one image and i think i got the angle a little off but the is some reduction still. however the color did wierd things. i will have to play with it some more!
Reply 7 years ago