New MentalRay shaders


I have made some MR shaders originally for Maya,
but since MR shader work across different packages I made 3dsmax gui declarations so they also can be used in Max.


A fisheye lens shader with extra parameters to get some funky stuff.


A panoramic shader with a field_of_view parameter to make it work from 0 to 360 degrees.
I have also added a automatic adjustment of the camera angle when field of view < 360.


A simple wood shader.


A phong wraplight material shader for MentalRay for Maya.
Made with help of:

In the example image you can see the top sphere with an ordinary phong shader lit from the sides.
Notice the dark shaded band around the center.
On the lower sphere the JS_wrapmaterial simulates the real world scattering of light that makes the lighting seem to “wrap” around the sphere and eliminate the dark band.
Adjust the wrap_factor for the wrap effect.

Mental Ray shaders



These look very interesting! Thanks bunches:beer:


sorry for me ignorance but what is mental ray shader all about?

regards, rohit


MentalRay is a renderer for Max, Maya and XSI.
MentalRay shaders are custom shaders for it.


How to install shaders like whirly in 3dsmax 6 available on the above mentioned website?

regards, rohit


The Whirly.dll goes in: 3dsmax6/mentalray/shaders
The Whirly.mi goes in 3dsmax6/mentalray/include

Sadly the shader presets included with the dll are for XSI only. :sad:


Those preset are cool & it’s sad to know that they are not for max. Anyway downloaded whirly.mi which was not included in the zip folder.

I can see the shader but don’t know how to use it.

thanks, rohit


First. I did not write the Whirly shader that was a guy called G. Mohan. I have simply written the Whirly.mi file so that it could be used with Maya and Max.

The shader outputs a scalar (float) value from 0 to 1 but since Max doesnt seem to like scalar output from a shader I use my MR shader Plaincolor to convert its float value to a value from black to white. You can get it at my site.

I´ve made a short guide on how to use it in Max.
Here we go…

Create a material, standard will do, and click on the diffuse color map.
Select Gradient Ramp and set the Gradient type to Mapped.
Right click the middle gradient flag and delete it.
Click on Source Map and choose Plaincolor.
Set its color to white and map Whirly to the brighness value.
In the whirly shader click on the Coord map and select UV Generator.
Assign the shader to a object and render using MentalRay.
Now you´ll have a grayscale pattern that could be used for bumpmaps or displacement.
Play with the settings in the Whirly shader until you know what the different settings do.
Now go back to the ramp and change the colors by right clicking on the ramps flags and choose Edit properties.
Add new flags by clicking in the ramp and then change their color to whatever you like.
Render away!


clicked on source map but i don’t see any ’ plaincolour ’

regards, rohit


Plaincolor is a MR shader. You can get it at my site.


Thanks pixero. I’ll definitely go play around with those new shaders you’re sharing with us :slight_smile:

I can never have enough shaders!


PHEN 0.2 error 051011: shader “Whirly” not found

This is what i get when i render the scene. I followed all ur instructions & whirly is installed then why this error?

regards, rohit


MentalRay shaders need two files to work. A .dll and a .mi file.

The error means you dont have the Whirly.dll in the right directory.

Whirly.dll should be in: 3dsmax6\mentalray\shaders
Whirly.mi should be in: 3dsmax6\mentalray\include

Get the Whirly.mi file from my site here
and the Whirly.dll here


thanks for all the effort & does preset creation requires good scripting knowledge? I liked all those presets & want to achieve all those results. That will be great!

regards, rohit


This thread has been automatically closed as it remained inactive for 12 months. If you wish to continue the discussion, please create a new thread in the appropriate forum.