mental ray’s GPU accelerated GI engine prototype

Autodesk 3ds Max 2015 and Autodesk Maya 2015 ship with mental ray 3.12 which includes a prototype of our new global illumination engine accelerated by the GPU.  We encourage our 3ds Max and Maya users to try it out. Your feedback will help us in making this a big step forward into the future of rendering with mental ray. While the current version is in prototype status and not yet feature complete, we are constantly improving the algorithms and adding new features. Your input is most welcome in this process.

The key idea of the new GI engine is full and exact simulation of the lighting interactions in a scene. This way, we overcome drawbacks from caching techniques and interpolation, and make mental ray more interactive and predictable. The brute-force raytracing approach is accelerated on CUDA capable NVIDIA GPUs making it particularly attractive in this set-up. Its result gets combined seamlessly and automatically with the primary rendering done on the CPU. This ensures full compatibility with existing custom shaders, which do not need to be touched in order to take benefit of the new GI engine.

The following Maya scene is rendered using the new GPU GI prototype in 11 min 34 sec (2 x Quad-core Xeon E5620 @ 2.4 GHz in hyper-threading, 8 GB RAM, Quadro K5000)

Mosque - mental ray 3.12 GI GPU diffuse

                                                                                            Autodesk Maya scene courtesy Lee Anderson, environment from openfootage


For comparison, this image is rendered with the classical finalgather automatic mode in 20 min 52 sec (2 x Quad-core Xeon E5620 @ 2.4 GHz in hyper-threading, 8 GB RAM, Quadro K5000)



In the current version, the GI GPU mode considers diffuse-diffuse bounces only, similar to what final gathering typically computes.  In fact, if this mode is enabled without setting further parameters then finalgather settings are used to derive reasonable default  parameters to render towards the same quality. If certain prominent ray tracing effects like mirror reflections or transparent  windows are not used in a scene then the fastest diffuse mode is best suited. For current limitations, see below.


The following image is rendered with the GI prototype in diffuse mode in 37 minutes (Core i7-3930K (6 cores), 16 GB RAM, Quadro K5000)

Medieval - mental ray 3.12 GI GPU diffuse

                                                                                                                                             Autodesk 3dsMax scene courtesy David Ferreira


The following 3dsMax scene is rendered on the CPU with finalgather force in 13 hours (Core i7-3930K (6 cores), 16 GB RAM, Quadro K5000)

Medieval - mental ray 3.12 CPU


The GI GPU mode can be enabled and controlled with scene options or on the command line of the standalone mental ray. We also provide scripts for Maya and 3dsMax that provide a simple GUI for enabling GI GPU (see screenshot). Please, note, that this is by no means how we envision it to be integrated in the applications. It’s rather to provide easy access to users that would like to test the prototype.



Script Download

The scripts to easily enable and access the GI GPU prototype can be downloaded directly from us here:


Current limitations

GI GPU transfers the scene geometry, presampled shader data, and some constant amount of buffer memory onto the GPU. Textures are not needed on the GPU. In the case that the GPU memory is not sufficient, there is an equivalent CPU mode. The new GI engine can still be used but the GPU acceleration must be disabled (uncheck the ‘Use GPU’ checkbox). There is also an absolute limit of 25 million triangles.

For GI GPU to be effective, finalgather must be turned on. Some features are not yet supported: distorting lens shaders, motion blur, particles, volume shaders, camera clipping planes, progressive rendering. There is only limited support for scattering shaders, emissive materials, and hair rendering.

Before testing GI GPU, we recommend to install a recent version of the NVIDIA graphic card driver.


Feedback and discussion

We would like to hear your feedback and see your renderings using this prototype.  Please join our NVIDIA Advanced Rendering forum, if you have not already, and send us your comments and discuss the mental ray GI GPU prototype.  The dedicated mental ray GI GPU Prototype forum topic here

48 thoughts on “mental ray’s GPU accelerated GI engine prototype

  1. random4925 says:

    Why are you using Quadro cards for tests and benchmark examples? They are mostly useless for rendering as they have very few Cuda cores. You should develop, test and benchmark on Gforce and Tesla cards exclusively. Just mentioning and using Quadro card in a GPU acceleration context suggests you are unaware of which is the correct hardware to use for the task.

    1. nvjulia says:

      The Quadro K5000 is a certified GPU for both 3ds Max and Maya 2015 and a card often included in professional workstations. We do preform benchmarks and testing on various NVIDIA GPUs but for this post we chose the K5000. You are correct, the higher CUDA core count the better the card preforms for CUDA based raytracing operations.

  2. nvjulia says:

    Hi Alex,

    GPUs accellerate the rendering but we don’t rely on them. You can still run the new GI engine prototype on your renderfarm using the CPU mode.


  3. Rara says:

    *is this absolute limit of 25mil triangles temporary and for prototyping reasons, or rather it is a limit imposed by the architecture of the new engine itself?

  4. On Linux, I get the following error:

    MB warn (…): loading /usr/autodesk/mentalrayForMaya2015/bin/ cannot open shared object file: No such file or directory
    MB error (…): GPU-GI not available (Could not load plugin /usr/autodesk/mentalrayForMaya2015/bin/

    Using Centos 6.5 and Maya 2015 SP 2. I could not found any library like that in my packet management.

    1. nvjulia says:

      On Linux, you have to add the mentalray bin directory to the LD_LIBRARY_PATH, e.g.’setenv LD_LIBRARY_PATH /usr/autodesk/mentalrayForMaya2015/bin:$LD_LIBRARY_PATH’.
      Hope that helps!

      1. MP4 says:

        It seems that I get similar error, I am on Macos 10.8.5:

        LIB 0.3 48 MB warn 292014: loading /Applications/Autodesk/mentalrayForMaya2015/bin/gpu_gi_plugin.dylib: dlopen(/Applications/Autodesk/mentalrayForMaya2015/bin/gpu_gi_plugin.dylib, 1): Library not loaded: @rpath/liboptixu.1.dylib Referenced from: /Applications/Autodesk/mentalrayForMaya2015/bin/gpu_gi_plugin.dylib Reason: image not found
        GPU 0.2 48 MB error 871001: GPU-GI not available. (Could not load plugin /Applications/Autodesk/mentalrayForMaya2015/bin/gpu_gi_plugin.dylib.)

      2. nvjulia says:

        On MacOS, it’s the DYLD_LIBRARY_PATH that needs to be defined, e.g. ’setenv DYLD_LIBRARY_PATH /Applications/Autodesk/mentalrayForMaya2015/bin’ prior to starting Maya2015. Sorry for the inconvenience!

  5. Dizzy says:

    This is great to see! Is the intention to eventually use the GPU for more than just GI calculations? I envisage using mr in the future, and the GPU assisting the CPU with more than just the GI part of the render.

  6. Hi developers!…. I was the only betatester of Nvidia Gelato in Spain back in 2005 if I recall properly and I hope we will get a better approach this time with this new render engine. I’m installing the prototype right now and I hope to be of any help with the betatesting.

    Good luck!

  7. THANKS for this! I use MAX and I’ll definitely test it on my laptop with an i7 quad and dual GTX 780M cards as well as the workstation with 2×10-core Xeons ans GTX 780 🙂
    This should speed things up considerably!

  8. BoulderFoot says:

    I’ve tried this script on Maya 2015 SP2 on a Windows 8.1 machine. It has a nVidia GeForce GTX 750Ti with 2 Gb VRAM and once I enable the GI on the GPU and hit render, it crashes Maya on a very simple scene. I’m wondering if it is because of the GPU being based on the new Maxwell architecture?

      1. Yeah, I’m running driver version 337.88 which is as far as I can tell the latest WHQL certified drivers. There are some newer Beta drivers (340.43)

      2. BoulderFoot says:

        Just a FYI, my problem is now resolved. I installed SP3 but I also noticed that there’s a seperate update for mental ray to SP3. SP2 had the same thing but not SP1 so I suspect I might have not updated mental ray to SP2 while Maya was SP2.

        Happy days! 🙂

  9. Hi! I am unable to achieve depth of field in my renderings when using this GPU GI prototype. Is there something I need to change/enable or is it just something that was overlooked in the prototype?


  10. I try on 3ds max 2015 with gtx 570 –
    the gpu work well – but i see this error and message, on render message Windows

    DB 0.4 193 MB error 041012: attempt to unpin null tag
    RC 0.3 160 MB warn 082139: FG+IP, setting the FG diffuse depth to 0 and the IP indirect passes to the current FG diffuse depth (1)
    RC 0.3 160 MB warn 082142: FG+IP, setting the IP interpolation to “always”
    RC 0.3 160 MB warn 082157: irradiance particles cannot be used with GPU GI

    I’am work with Fg on – and gi gpu on –
    the final rendering is more bright, compared to rendering without GI GPU on

    what is this error ? ( DB 0.4 193 MB error 041012: attempt to unpin null tag ) and how I can remove it?
    What string options I can put, to remove the warning?

    Thank you,
    Best regards

    1. cassnv says:

      Marcello, We are investigating the unpin issue, thanks for reporting.
      Irradiance particles cannot be used with GI GPU, to remove the warning please disable irradiance particles.

      1. Hello, Cassnv
        yes I know that not work with irradiance P. but is strange becasue I not insert the IP in my original scene.
        the warnig is present when use the script or string option and activate the GI GPU.
        why the irradiance particle is present if If activate the script GI GPU ?
        is possible to turn off the irradiance Ip with a new string option ?
        for disable the IP with the gi gpu.
        best regards

      2. cassnv says:

        Marcello, We are unable to reproduce this. Please visit the mental ray forum and create a topic in the GI GPU section with your scene and setting details. Link here.

  11. Hi Alex,

    GI on the GPU would be an excellent and fast look development tool on local workstations. Eventually upgrading the render farm would be useful to have similar render times. The results between CPU and GPU are identical. Once it is out of the prototype phase you can make complete use of it locally for artists and begin populating the render farm over time.

    In my tests, the prototype performs well compared to other rendering solutions on the CPU so it’s still good for CPU fallback on a farm.

  12. Jim Duvall says:

    Hello, sorry for reviving an old thread, I finally upgraded to a cuda graphics card (gtx 970) and tried to use the script on 3ds Max 2015 (with SP3). When I use the script on a very simple scene I get the error:

    0.5 22MB Fatal 0111111 Unknown Exception Thrown
    0.5 22MB Fatal 0111111 Unknown Exception Thrown

    And then freezes up and crashes. Any thoughts to resolve this?

    Thank you in advance.

  13. Hi, i’m not new to Maya but Iam new to using Mel Script. I have tried to apply this Mel Script to my Maya Mel Editor, then applied it to my custome shelf. But can not seem to get it to work could someone post a tutorial or a walkthough just so i know i doing it right.

    Thanks in advance.

  14. Daniel says:

    I cant to install the script in may 2015. Does not execute the window after to paste in Script Editor
    Can you help me? please.

  15. bgawboy says:

    Please note that 3ds max 2017 includes the latest GI with GPU acceleration in the UI. No script needed. Depth-of-field, motion blur, everything should be supported.

    1. nvjulia says:

      You can download the script and copy it into your personal script folder (eg Documents/maya/2015/scripts).
      Then, after starting Maya, you can call GI_GPU() from the script editor.

      Hope that helps!

    1. bgawboy says:

      No, in 3ds Max 2017 you should be using GI Next, which is directly incorporated into the UI under Global Illumination tab of Render Setup, above Final Gathering.

Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s