thank u very much, I’ll look into that.
enjoyMentalRayStringOptions, a UI to easely use MR string options
Hello.
I’m getting this error when I attempt to render or batch render:
// Error: Cannot use data of type no type in a scalar operation.
It’s an immediate error and the render does not even start.
I’m using 2012 SP2. This error doesn’t occur in 2011. I haven’t tried on a pre-SP2 2012 machine (don’t have access to one).
Edit: It seems to be scene-specific. If I enable Unified Sampling and the restart Maya and load the scene, it renders. However, if I open the string options UI, then the render fails with the above message.
Check your miDefaultOptions node in the string option tab. See if there is no strange types. :sad:
A very (very) little update:
Add “light relative scale” string option that should help to solve this kind of problem:
http://forums.cgsociety.org/showthread.php?p=7269031#post7259091
:wavey:
Following this page, four new string options will be added soon:
http://docs.autodesk.com/MENTALRAY/2013/ENU/mental-ray-help/files/manual/upgrading310.html
“trace camera clip” on|off
“trace camera motion vectors” on|off
“detail shadowmap contrast” color
“hair acceleration” on|off
Tell me if I’ve miss one. ![]()
If you look in the release notes (not just ‘what’s new’) you will see additional options for importance sampling with FG+IP (and importons)
For now we find FG + Importons to not be a significant help, but FG+IP can be faster in complex lighting than either one alone.
Refurbished finalgather + irradiance particles combination in order to allow irradiance particles to drive finalgather importance sampling.
Added string option “finalgather importance”, with the following possible values:“off”: If irradiance particles are on, their contribution is used for the computation of the secondary diffuse component. Irradiance particles are not applied to drive importance sampling for finalgather rays
“partial”: the importance-based mechanism of irradiance particles is used to drive finalgather ray distribution, and irradiance particles are used for secondary diffuse bounces.
“full” or “on” : like “partial”, and in addition for shading of finalgather rays, light sampling loops would return black and the direct diffuse illumination is obtained from the irradiance point maps. Note that in this mode, the glossy component of finalgather ray hits is suppressed, which may read to slightly darker images.
In addition, finalgather can be used with importons without irradiance particles. In that case, importon map drives finalgather ray distribution.Experimental: for finalgathering, added an experimental finalgather lookup mode which tests the visibility from the lookup point to the FG interpolation point candidates. The mode can be enabled with the “finalgather points test” string option, or with the new miIrrad_options::finalgather_points_test value set to 1.
Ok! Interesting!
I’ve done a little list of what I will add.
I just need you guys to find the default values (and maybe “in one line explaination”).
http://docs.autodesk.com/MENTALRAY/2013/ENU/mental-ray-help/files/manual/upgrading310.html
“trace camera clip” on|off (default off)
“trace camera motion vectors” on|off (default off)
“detail shadowmap contrast” color (default 0,0,0)
“hair acceleration” on|off (default on)
http://docs.autodesk.com/MENTALRAY/2013/ENU/mental-ray-help/
“progressive subsampling size” <int> (default ?)
“rast hair disposable” <bool> (default ?)
environment lighting scale" f [f f f] (default ?)
finalgather flip bad geom normal" <bool> (default ?)
“light relative scale” <float> (default ?)
“hair caps” <bool> (default ?)
“geom displace motion factor” (default ?)
“finalgather precomputation legacy” (default ?)
“metasl technique” (default ?)
“finalgather importance” (off|partial|full) (default ?)
“ray differencials” (default ?)
“finalgather points test” (default ?)
“contrast all buffers” (default ?)
Notice that some of them are maybe already in enjoyMentalRayStringOptions. I’ve just listed what I’ve found.
Any help is welcome! 
I would:
Make light relative scale default and always on, no real reason not to now that BSDF shaders are exposed.
Omit the experimental FG point test, I had artifacts.
FG importance to Off as default (legacy behavior, note: if selected with FG+Importons it should be ‘full’)
Contrast all buffers on by default
Omit FG flip geo normal
Probably omit metasl for now. . .for reasons that might be clear later.
I’ve worked a little on it and still need some informations for this options:
http://docs.autodesk.com/MENTALRAY/2013/ENU/mental-ray-help/files/manual/upgrading310.html
“detail shadowmap contrast” color (default 0,0,0) << I used a scalar instead of color. Is this ok?
http://docs.autodesk.com/MENTALRAY/2013/ENU/mental-ray-help/
“rast hair disposable” <bool> ? should be off?
“hair caps” <bool> default?
“finalgather precomputation legacy” ??? Is this a bool value?
“metasl technique” bool?
“finalgather importance” (off|partial|full) default?
“finalgather points test” bool value?
I suppose every bool value is supposed to be off by default… I just want to be sure.
By default value I mean:
“have the same render with the string option and his default value”
Small warning: using finalgather legacy ‘on’ with some new features may causes crashes
Should default to “off” now.
Thanks for report. I finalgather legacy is already off by default in my script. 
For the rest I should maybe directly ask the mental ray forum… :shrug:
Hi there
Would like to thank you so much for this great little script 
If I can ask, could you please add the Importons options aswel? It would be nice to have all of the frequent settings in one place.
I have bookmarked this page and I am looking forward to updates 
Keep up the great work!
Hi and thanks!
What do you mean by Importon options? Every importon string options are there no?
If you see a missing string option, don’t hesitate to tell me.

Hi Narann
The options im looking for are
Importons
“importon” on|offIf enabled, the importons are emitted and importon map is created. The default value is off.
"importon density"densitySpecifies the approximate number of importons shot from the camera per pixel. The minimal value for this option in the current implementation is 0.02, i.e approximately 1 importon per 50 pixels. The default and recommended value is 1.0. Lower values will speed up importon emission, but could lead to less optimal photon map and decrease final image quality.
"importon merge"mergeSpecifies the world-space distance used to merge importons closer than that distance. The default value is 0.0, which means that merging is disabled.
"importon trace depth"depthintControls the diffusion of importons in the scene. If set to zero, importons will not scatter on the diffuse bounces. This is the default. In some cases it may be required to use more than a single diffuse bounce. This is the case if the combination with final gathering is used, or when the “importon traverse” option is switched off.
“importon traverse” on|offEnables a special behavior of importons shoot from the camera. Such importons would not be blocked by even completely opaque geometry. Instead, they would be stored for all intersections with geometry on the ray from the camera to infinity. This leads to a significantly higher number of importons stored in the scene. However, it removes the discontinuity in the distribution of the importons originated from the visibility to the camera function. The default value is on.
From mental ray documentation
The String options is there, but If you could, could you please add it to your UI 
It is much easier to choose the settings from your UI
Thanks alot