How do you get manual dof to work? I've been playing around in the settings but can't seem to get my sim in focus, they just stay blurry
This is going to be a long post.
Manual DoF can be a little fiddly until you get to grips with the focus settings, but once you do it’s pretty easy.
First, I created a little DoF overview some time ago that goes over some of the basics and I recommend reading that first (just to make sure you’ve got the depth buffer set up correctly and so on), but I’ll go over how to use manual focus in more detail here.
Note: I’m going to assume you’re using the standard DoF.fx shader, which includes matsodof, ADoF (MartyMcFly) etc. Control of focus works altogether differently for Cinematic DoF, and I won’t cover that here, but once you’ve worked out how to use regular DoF it’ll be easy to transfer that knowledge across. If you’re using qUINT’s DoF the basics of manual focusing are the same as I’m about to cover.
Obviously, you’ll need to un-check the boxes for auto-focus and mouse-driven auto-focus, and this will automatically switch it over to manual control.
There are three settings you want to concentrate on:
These three settings work in tandem. Manual Focus Depth is only ever used when using manual focusing, whereas Near Blur Curve and Far Blur Curve can also be used with auto-focusing, so what you learn here about them can be useful if you ever switch back to auto-focus again.
To use manual focus we need to understand how depth of field focus works. Take a look at this picture:
In this picture, Focal Plane is what we know as Manual Focus Depth; Focal Plane Near Limit is what we know as Near Blur Curve; and Focal Plane Far Limit is what we know as Far Blur Curve. The camera on the left is you, or the game camera; and the mountain on the right is whatever is farthest away in the distance in the game, usually the sky and fake background scenery.
When trying to get something in focus, what you’re doing is trying to work out at which point between you (the camera) and the far distance (the backdrop) that thing you want in focus lies.
In the DoF shader, a numerical range is given from the camera (the closest point) to the background (the farthest point). This range goes from 0.0 to 1.0, with 0.0 being the camera and 1.0 being the farthest point away.
We want to set Manual Focus Depth to the correct point along that 0.0-1.0 range, so our subject (let’s say it’s your sim) is in focus.
You can put your mouse inside the box and drag it from left to right to change this value, or you can double click (in 3.x versions of ReShade) or right-click (in 4.x versions) to manually type in a number.
Manual Focus Depth has a very sensitive scale, and so you may find it easier to control focus by typing a number in rather than just sliding. This way you can also change it in smaller increments, going as far as three decimal places: 0.056 might be just the exact distance you need, whereas 0.05 or 0.06 might be wrong.
I find for a lot of close sim portraits that a value of between 0.01 and 0.04 is usually best, but it will depend on how close you have the camera to the sim (I tend to have it quite close). If you just want a gentle blur in the far distance, with most of the scene in focus, you might find a value of something like 0.2 or 0.3 or even 0.4 is better.
These numbers seem quite small considering we’re talking about focus that can be quite far into the distance, but that’s just a quirk of how the depth is calculated, and you soon get used to which values feel about right.
Let’s experiment: go ahead and set Blur Radius relatively high (about 15 would be strong enough), and slowly move your mouse left and right in the Manual Focus Depth box and look at what happens on the screen.
If you move it slowly enough you should see various things come in and out of focus. This will help you understand what to expect when adjusting Manual Focus Depth. The further to the right you move your mouse, the higher the value, and things farther into the distance will come into focus. The further to the left you move your mouse, the lower the value, and things closer to the camera will come into focus.
Now, set up a scene and position your camera so that there is a sim or a nice plant or something that you want to be in focus quite close to you. Now, move your mouse very, very slowly in the Manual Focus Depth box and see if you can catch the moment when that sim or plant comes into focus. If the sim is close to the camera you should expect the value to be very low (as I said before, maybe 0.01-0.04).
Once you have the focus in more or less the right place you might find you have to adjust it more carefully by clicking in the box and typing in a number (for example, 0.024). This can require some patience until you’re used to doing it, but you quickly get a feel for it.
Now, because we’re using such small increments, once you’ve got the Manual Focus Depth set up perfectly for your current subject, if you move the camera forward or back at all you’ll find your sim is no longer in focus, and you’ll have to adjust the values again to compensate. This is because manual focus, once set, is static: if you tell it to focus on something 0.04 away from the camera, it will focus at whatever is 0.04 away from the camera, regardless of where you move the camera to.
To give a better idea of what I mean by that, stick your arm out in front of you where you’re sitting so your fingertips touch your computer monitor. Imagine the distance between you and the tips of your fingers is 0.04. Now, get up and move somewhere else in your room, and keep your arm extended in front of you until you’re touching something else with your fingertips. Now that new thing you’re touching is 0.04 away from you, not your computer monitor. If you were actually stood in the game and using DoF, whatever is at your fingertips would be in focus, so by moving around your room your computer monitor goes out of focus and whatever you’re now touching goes into focus. This is what happens when you move the camera in the game once you’ve set up your Manual Focus Depth. So if you still wanted your computer monitor to be in focus you’d have to tell ReShade that the Manual Focus Depth is now a different value, a different distance away from you.
So, we’ve got our sim in focus now and we’ve got a better understanding of what Manual Focus Depth is and how it works. That’s most of the work done. And perhaps you’re perfectly happy with how it looks now and don’t need to alter the focus any more. Great! You can change the Blur Radius so the strength of the blur is whatever you want, and go ahead and take your picture.
But perhaps you want to change how the blur works a little more. This is where Near Blur Curve and Far Blur Curve come in.
Looking back to the picture above, you can see that we can get blur in front of our subject and behind our subject. Using Near and Far Blur Curve we can push the blur further away from our subject, so the area of that is in focus is bigger, so more is in focus. Conversely, we can use Near and Far Blur Curve to pull the blur closer in to our subject, so less of an area is in focus. In the picture above, everything that lies inside the two outer lines is in focus, and everything that lies outside the two outer lines starts to become out of focus (with the Focal Plane, or where we set Manual Focus Depth to, being the precise point of absolute focus).
With Near and Far Blur Curve, lower numbers pull the blur closer to the focal plane (our subject, or Manual Focus Depth), and higher numbers push the blur further away.
For the most part, I set Near Blur Curve as high as it will go, because I don’t generally want any blur between the camera and my subject except in very specific circumstances (in which case I usually use Cinematic DoF for it because it handles it better). So, if you’re the same as me, go ahead and set Near Blur Curve to 1000.00 and forget about it.
If you’re taking a lot of portraits and want the whole background blurred, you can probably leave Far Blur Curve at its default. If you find things start getting blurry too fast after your in-focus subject (your sim, your nice plant, your beautifully-arranged pile of books, or whatever) you can increase the Far Blur Curve value and push that blur back a bit until it looks as you want.
Near and Far Blur Curve values aren’t as sensitive as for Manual Focus Depth, so you should be fine just using your mouse to slide from left to right.
As I said earlier (84 years ago; I’m sorry this is a long post), Near and Far Blur Curve can also be used with auto-focus to control the fall-off of the blur in the same way. Getting to grips with Manual Focus Depth is really the important one when using manual focus. Yes, it is frustrating at first, and doesn’t seem to make sense, but take your time and it’ll suddenly click in your brain and from that point onwards it’ll take you no time at all to set up focus how you want. This post is only as long as it is because a) I insist on explaining all the whats and whys as well as the hows, and b) I’m too verbose. It’s actually a quick process once you understand it.
There are some quirks as to how focus works. For example, Near Blur Curve is a bit buggy in the DoF.fx shader with ADoF (Marty McFly DoF), but it works as it should in the qUINT DoF shader. But as you get used to using manual focus you’ll learn what those little quirks are and develop your own strategies and workarounds.
One day I’ll get around to making a far more user-friendly tutorial for this, but today is not that day because I’m wordy rather than visual. Still, read slowly, take the steps slowly, and it should make sense.