← All ideas
  • Published 28 Nov 2025

Add a DEFAULT OSL Camera Shader with Artistic Standard Bokeh Controls

A default OSL shader with these controls would be beautiful (so we don't all have to code it ourselves).

BOKEH DENSITY Bokeh Density.jpg A crucial effect for realistic renders. A negative density makes the edges of a bokeh circle appear brighter than the center. All real camera lenses have this to varying degrees. But blender only allows us to use "Density 0".


ANAMORPHIC BOKEH / Aperture Ratio anamorphic_bokeh-1024x696.jpg We technically have this but its currently bugged.. more here: blender.community/c/rightclickselect/XQwo/ It's an absolute must for realistic cinematic style renders.


Custom Aperture Maps

Screenshot 2025-11-28 225408.jpg

A lot of creators create amazing Aperture maps which can be used in other render engines to give one's bokeh a distinct stylized touch. I think we deserve the option to use these as well in our projects.


FOCUS STACKING Focus_stacking_Tachinid_fly.jpg An effect used mainly by macro and product photographers which allows the user to not just have one single spot in focus. Instead the user can define a focus zone in which the entire subject is completely in focus. Everything outside that focus stacking zone receives the normal aperture bokeh blur.


BOKEH IMPERFECTIONS / DIRT

Bokeh Imperfections,Dirt.jpg

Usually camera lenses have some level of imperfections, dust and dirt visible in the Bokeh. A simple setting to add a imperfection texture or noise would add a lot of realism.


SWIRLY BOKEH VIGNETTING

bokeh swirl.jpg Bokeh vignetting gives the cat eye swirly effect effect. A camera lens effect, which causes the bokeh to become more and more deformed and circular toward the image edges. All camera lenses have this to some degree.


Thanks for your consideration ^^

100%

Development Status: Open

Upvote 5 Downvote 0
Yannik-Pipek
28 Nov 2025

3 Comments

gwetell

Yeah I think a good and versatile OSL camera shader should be in Blender by default, but seeing it's not in you can just get Lens Sim addon (the lite version is enough) and you'll have exactly what you're looking for.

1
1
Yannik-Pipek Author

I think it's far from reasonable that every single Blender user has to rely on writing their own OSL code, or resort to randomly purchasing presets from other users, like the one you linked.

Most of the functionality mentioned by me is pretty standard everywhere else, and I don't think we should have to struggle to get something as fundamental as bokeh density or proper anamorphic bokeh controls. Also, some effects like focus stacking cant be done with the current OSL at all (i think).

3