This location is for Registered Users Only.
Perhaps you need to login or register.
11.0, 10.5 or later
Being into photography before I knew what VFX was, acheving more realistic bokeh in Nuke has been one of my goals as a compositor ever since I saw what the Defocus node does for the first time. Years later, this is my second serious attempt at accomplishing that goal, and the first tool I am sharing on Nukepedia. To get things started, here is a nice article on bokeh with pretty pictures: Understanding Bokeh
Compare the perfectly uniform and round bokeh in the above right image with the 'cats eye' shapes appearing around the corners of the first image. You can get fancy with filter shapes using Convolve or ZDefocus, but it still doesn't address the uniform CG look.
There is a preview feature so you can easily see the characteristics of disotrtion, with a yellow crop warning that appears when you need to increase the 'Overscan' slider. There are some distortion presets that could be used as a starting point.
The Cat's Eye is an independent parameter from distortion, so you could bypass the whole distortion setup and just apply cat's eye for subtlety.
These are some filter shape presets I came up with by playing with the sliders in the UI. These are not image files so you can pick one and move some sliders to come up with totally different looks. I recommend using the Filter Preview when tweaking these. An external image can also be used, which I only implemented while rendering out internal filter resuts, but then realized it could be used to build a personal library of interesting filters.
Some more examples showing different combinations of distortion and filters. I used a jpeg as my image source, but if you use it on an image with more dynamic range then the variance in the filter details really start showing.
Now on to the UI:
Many of the sliders/buttons have more information when you hover over them.
There are a lot of controls, but a lot of the irrelevent menu get hidden depending on your selection to make it easier to use. I tried to include only the essential features that cannot be done outside of this tool, so there is no option for heavy handed grading, vignette, etc. I am on the fence about chromatic abberation though because with the distortions happening applying it after the fact may not give the same results as applying it internally. If you have other suggestions please do let me know.
It should be noted that this version only applies the same amount of defocus to the entire frame. I am also working on a version that applies variable depth of field. It needs some extra features on top of this one so I will wait till this one is more or less final.
This is a sneak preview of a possible future update. While the current version is barely adequate for moderate amount of bokeh distortion it can't even come close to matching extreme real life examples. The above image is a test with a different approach that can push things further. It looks promising, but the challenge will be analyzing the behavior and breaking it down into few simple controls that affects multiple variables.
Finally some known bugs in this release that has no effect on performance as far as I can tell:
-When you close the node properties while the defocus method is not set to 'Filter', next time you open it a bunch of filter menu becomes visible that shouldn't be. Clicking on 'Filter' and clicking again on 'Defocus' or 'Disc' fixes the problem. This problem is due to me being a python noob. If anyone could help solve this it would be appreiciated.
-In the node graph, there is a little gray 'x' box above the node. It wasn't there a couple of days ago and I do not know how to get rid of it.
So far I've only tested it on Nuke 10.5 on Windows. Please let me know if you try it on other OS and Nuke versions wheter it runs perfectly or you run into issues.