We also demonstrate the OpticalZDefocus gizmo, which is a tool for generating physically accurate depth of field. It does this using the depth of field equation, given lens characteristics and a focus distance.
How depth of field can be simulated in Nuke
with the ZDefocus tool.
You can set your lens and film-back characteristics, set your focus distance, and adjust the size of your bokeh with the aperture f/stop size, just like a real lens.