PDA

View Full Version : customized camera



emanuelshalev
September 15th, 2015, 18:33
I would like to achieve customized camera behavior. For starters I would like the geometry model of the lens to be very specific, what is the right way to achieve this customization?
The scene will need to be rendered in Maya and in MentalRay standalone too.

Can anyone help or give me a pointer on a relevant sample or explanation?

Any help will be really appreciated.
thanks,
Emanuel

bart
September 16th, 2015, 19:17
What is your experience with writing mental ray shaders? Have you read the book Writing mental ray Shaders? There is a chapter specifically on lens shaders.

bart
September 16th, 2015, 19:18
Or have you investigated the bokeh lens provided in order to see if it serves your purpose?

AndrewHazelden
February 20th, 2016, 10:25
Hi. Besides the mental ray examples provided by the official mental ray programming guide books, you can look at the following 3rd party open source mental ray lens shaders for code snippets to get you started.

Cheers,
Andrew Hazelden

Domemaster3D - angular fisheye, latlong 2D / stereo 3D lens shaders
https://github.com/zicher3d-org/domemaster-stereo-shader

https://github.com/zicher3d-org/domemaster-stereo-shader/tree/master/mentalray/Domemaster3D%20Installer/installer%20files/Domemaster3D/sources

http://www.andrewhazelden.com/blog/2012/04/domemaster3d-stereoscopic-shader-for-autodesk-maya/

https://github.com/zicher3d-org/domemaster-stereo-shader/wiki

Pixero Shaders - js_fisheye and js_panoramic
http://www.pixero.com/downloads_mr.html

Ralf Habel shaders - cubemap_lens and latlong_lens
http://www.andrewhazelden.com/blog/2011/01/latlong_lens-and-cubemap_lens-mental-ray-shaders-compiled-for-maya-2011-x64-on-windows/

Witness Shaders - fisheye with a blog post too
http://the-witness.net/news/2011/01/adventures-in-fisheye-lenses/

The Fulldome Blog List of Lens Shaders
http://thefulldomeblog.com/2013/06/28/fisheye-lens-shader-options/

maxt
January 4th, 2017, 17:28
Just for completeness, Rombo.Camera can fully simulate a multiple 'thick' lens system where one can even input his own lens design.
http://www.rombo.tools/2016/03/27/thick-lens-setup/

Eventually, there's a full lecture on youtube about thick lenses :
https://www.youtube.com/watch?v=2EUzr8fP0TA

AndrewHazelden
January 4th, 2017, 17:45
Hi Maxt.

Thanks for posting a link to Rombo.Camera! It is a really interesting approach that the lens shader has taken to accurately model the lens properties.