Hi gang :)
I'm trying to add some DOF to an image I recently made following the dof tutorial om the nwda site and I'm running into some issues. I've kept the camera settings the same (disabled shadows, atmosphere and lights) and replaced the colour channel with a distance shader. The results I'm getting are just plain weird and I'm stumped for a reason.
Attached images.
cheers
Richard
ps the tree line has actually been disabled as I only need the dof info for the foreground, they would render black anyway.
Sorry.... I have no idea. Doesn't look quite right though, does it? ???
Really tough to say what is going on without a project file, or at least some node network screenshots of how you have the distance shaders set up.
With all the objects in there it would be impossible to upload the entire project file (and they're partly XFrog defaults). I'll upload the tgd file sans the objects, you should still get an idea of whats going on.
The distance shader is the only shader on the coloured surfaces tab (theres a displacement for the mound) All the objects are shaded in the same way to the same shader (assign shader).
Richard
I can't really test this to make sure it works with your scene, but try changing the distance shader in your objects to be before the multishader/partsshader and not a specific node for each part on your object.
Here is an example scene that should show you where I put the distance shader for objects.
A bit more info about why your scene is turning out funny. When you set the distance shader as individual parts of the objects it screws up their geometry by ignoring the masks that they normally use. Attached are a couple images, one with the file I uploaded and another with the way you had it set up in your file. As you can see the tree loses the opacity mask information and the leaves render as simple polygons.
OK I figured it was something along these lines. So where would you put the distance shader so as to include the alpha masks. Thats what I've been trying to do. ALso this dont explain stuff showing up where there is no geometry! The sphere about the hilt of the sword for example.
cheers
Richard
I say you should just wait on the next TG release, Richard... ;)
Quote from: dandelO on November 12, 2009, 03:58:59 PM
I say you should just wait on the next TG release, Richard... ;)
::)
(sometimes i love this smileys more then ever)
;D
You saying that it cant be done in the current release and that this is a known bug that has/will be fixed in the next release?
Richard
You don't have the Reverse PR thing enabled right?
Richard,
Simply put the distance shader before the parts shader or multishader. I don't think there are any bugs at work here. See attached picture for further clarification.
Quote from: cyphyr on November 12, 2009, 04:15:24 PM
You saying that it cant be done in the current release and that this is a known bug that has/will be fixed in the next release?
Richard
No, I'm not saying it
can't be done in this release, it clearly can with TU's method.
Just that I noted in some posts a little time back here that were to include DOF in the camera settings for the next release. No more messing around with distance shaders. I'm pretty sure that's what I read.
I seem to remember that Jo, or Oshyan said that DOF may not be in the next release. But I could be wrong... It might be difficult to implement. Maybe that's why they are re-writing the renderer.
I might be mixed up, I'm half-sure it was posted here, though. I remember being excited.
You know how people tend to run with things and remake them in their own fashion, though, maybe I've just done that. Sorry if that's the case. :D
I thought I read that it had been.. emm retracted also, because of something or other.
Quote from: RArcher on November 12, 2009, 04:50:49 PM
Richard,
Simply put the distance shader before the parts shader or multishader. I don't think there are any bugs at work here. See attached picture for further clarification.
Ah thanks, I hadn't thought of putting the distance shader that low down in the shader tree, looks to be working now :)
Thanks for the help
:)
Richard
Unfortunately that's true, DoF won't be coming in the next release. But this technique should still work.
- Oshyan
you also could try to use the "fog method". But the distance shader is the better way to go.
Quote from: Oshyan on November 13, 2009, 02:07:41 AM
Unfortunately that's true, DoF won't be coming in the next release. But this technique should still work.
- Oshyan
:'(