DOF Transition is Hard and Unrealisitc

Hi, I am noticing some bad hard transitions in my DOF. I am using an Empty to control where my DOF is starting. The empty is placed directly where you start to see the hard transition. (#1 in image)

Question (#1 in image)
Why is there this hard transition. I’ve exhausted all settings I can think of and it still remains. What’s causing it and is there a way to get rid of it? Using Blender 2.57

Question (#2 in image)
Also does anyone know why there are “empty” or missing spots in the render. See #2 in image. Using Blender 2.57

FStop: 10
Max Blur Limit: 0
Threshold: 1.000
Camera Focal Length: 35
Limits: Selected


No responses. Hmmm. Not encouraging. Could this mean there a failing with Blender’s DOF? I’m surprised nobody has noticed this problem before as it leave quite noticable and ugly artifacts making renders look really unrealistic.

pg

I believe you need to set the sampling mode to Full Sampling in the render settings.

Thanks Daccy. I selected “Full Sample” and even increased the antialiasing to 16 in hopes that it would help but it still rendered exactly the same as above image. Sigh…



Are you ultimately trying to do a “focus pull?”

Yes, Blender’s Defocus node can be artifact-prone. It’s been noted and mentioned for years but nothing ever gets done about it.

A workaround you might try: separate your scene objects into different Render Layers and use a separate Defocus node for each. In some cases this has fixed similar artifacts for my stuff. Otherwise, think about faking the DOF using Render Layers & Blur nodes with the Bokeh option.

sundialsvc4, thanks. maybe, but what is it? :slight_smile:

chipmasque,
thanks. Aww. I was hoping you wouldn’t say that. I was hoping it was only a setting I had overlooked. Thanks for the workaround, but too much work for what I want to do. Do you think the new internal render engine we’ve been hearing about will have a DOF or does the DOF (Defocus) node need to be updated?

DOF is so useful. Modo has amazing DOF and internal rendering. Let’s hope it get’s fixed.

pg

Example of a focus pull, aka “rack focus,” using the Defocus node and the BLenses POI constraint.

I have no idea whether any kind of different DOF implementation is in the works. That’s one for the devs to answer.

Cycles. Is it’s DOF any better?

Anyway looking at the example, I don’t recall any of my older DOF images looking that bad. Perhaps it is a 2.57 bug?

Thanks 3pointEdit. What are “Cycles”?
I found the DOF looks worse on objects that are coming forward and with straight lines like in my example. 3pointEdit, Do you have any old files you could open in 2.57 and try it out to see if you get similar results. I’d be curious if your results are any better.

pg

I’m nearly ready to bet the farm that where that artifact occurs, a background mesh terminates and you end up with no background (other than alpha-ed sky). Every time I have this sort of problem, especially when using Full-Sample (which is always a good idea w/DOF in blender), it has been because I am calculating DOF against nothing (alpha, e.g.), and once I throw some sort of mesh in the background, everything settles into place.

benu, that’s a great tip and makes good sense. Definitely worth a try.

Funny but I was just shooting (with a real camera) some extreme closeups in macro mode at f3 and got the same result, the DOF was razor thin and the edge was sharp. I thought I was magicaly transported into this thread :slight_smile: