Dreevoo.com | Online Learning and Knowledge Sharing
Home | Programs | The Gimp | Photo effects | How to do a simple DOF effect with Gimp
Click to view your profile

How to do a simple DOF effect with Gimp

Let me show you how to achieve that Depth Of Field effect known from the photography using Gimp. With other words, how to make selected area of the photo sharp and the rest out of focus.

  Author: TheDude | Version: 2.8.0 | 24th October 2012 |  

Open a photo in Gimp.


Press Shift + Ctrl + D to duplicate a layer.


Let's now make the photo blurry or out of focus.

In the menu click Filter, Blur and choose Gaussian Blur...

In the Blur settings window choose the same settings as I did and click OK.


Your whole image is now out of focus. What we need to do now is make a part of the photo sharp or in focus again.


Right click the duplicated layer ...


... and choose Add Layer Mask....


Now choose the Blend tool ...


... and set Radial as the Gradient (see picture).


Press D to set the black foreground color.

Now click and hold the mouse in center of the area you want it to be in focus then drag it out of the center (see picture).

Notice the circular area getting sharp again. How big will that area be, depends on how far you dragged your mouse.

The yellow line was added to show you how to drag your mouse. You can drag it in any direction you want and you can repeat the step as many times as you like to achieve the best result.


All that's now left to do, is the fine tuning.

In the menu click Colors and choose Brightness-Contrast...

In the settings window play with the both sliders and observe what happens.

If you slide the Brightness to the left the in-focus area becomes wider, if you slide to the left it becomes smaller.

If you slide the Contrast to the left the in focus area becomes softer and to the right it becomes sharper.

Click OK when done.


And that's my DOF photo of the Lego car.


And the close-up for the better perception.

  Please login to post a comment
  Click to open user profile  
vixxen, 2nd Jan 2013, 9:56 AM
For me, I get the opposite of what I should. It blurs the area I want it to stay in focus. What am I doing wrong?
  Click to open user profile  
TheDude, 2nd Jan 2013, 10:05 AM
Hey vixxen,

you have the white foreground color set instead of black when you are applying a gradient. Press D to set the black foreground and white background color. Check out the step 9 of the tutorial.

  Click to open user profile  
vixxen, 11th Jan 2013, 12:07 PM
Yes, that was it! I should have read a bit more carefully next time, thanks!
online learning made for people