Optimize Viewport 2.0

Optimize for scene complexity

Use these guidelines as ways to optimize Viewport 2.0 especially when your scene contains a large number of objects, includes high resolution textures, or if you need to simultaneously run other applications that use large amounts of GPU ram.

Enable GPU Instancing

GPU Instancing functionality renders large number of instances of a Maya shape that use the same material using hardware instancing. This reduces the computation load of your graphics card and provides large performance improvements for scenes with huge amounts of geometry or cached animation that does not fit in GPU memory.

Consolidate World

Consolidate World provides performance gains by combining the geometry all objects in the camera view to reduce the number of calls made to the graphics card. This option is on by default.

To optimize Consolidate World functionality, reuse similar shaders if possible, especially on small, static objects. You can do this by selecting File > Optimize Scene Size > and enabling the Remove duplicate: Shading networks option. You can take the most advantage of consolidation by selecting Shading > Use Default Material in the Panel menu to automatically use a single material in the viewport. If materials are not important to your workflow, this greatly improves performance in slow scenes.

Note: Enabling Consolidate World increases the graphics card memory. For more information see Manage GPU memory for Viewport 2.0.

Use Alpha Cut transparency

Select the Alpha Cut Transparency Algorithm under in the Viewport 2.0 options. This option provides high transparency quality without affecting performance. Alpha Cut works best on fully transparent or opaque objects.

Reduce memory used by textures

You can reduce the amount of memory used by high- resolution textures by turning on Clamp Texture Resolution in the Viewport 2.0 options. Setting this to Automatic allows Maya to automatically down-sample textures to conserve memory, or you can set it to Custom and set a particular max resolution. Maya will then down-sample any user textures above the max resolution.

Use Smooth Mesh Preview

Use Smooth Mesh Preview instead of smooth mesh deformers for faster performance. Note these improvements diminish when tessellation is enabled in real-time shaders such as GLSL or HLSL shaders.

Manage Viewport effects

You may experience performance slowdowns when using all of these features simultaneously:

  • Multisample Anti-aliasing Enable
  • Screen-space Ambient Occlusion
  • Floating Point Render Target

Disabling shadows can improve these slowdowns. As a general rule, enable these options for better visual quality and disable them for better performance.

Pause Viewport 2.0

To reduce the loading time of complex scenes, enable the Pause Viewport 2.0 (startup) option in the Display category of the Preference window. This lets you to make changes in your scene without having to wait for the viewport to update. You can also click this icon in the Status line to pause the Viewport 2.0.

Optimize GPU memory use

When previewing scenes with large amounts of textures, geometry, or cached animation, it is important to manage the amount of memory that Viewport 2.0 uses. See Manage GPU memory for Viewport 2.0.

Optimizing for animation

Shaders and texture optimization

DirectX 11 shaders

  • When working with the DirectX 11 AutodeskUberShader, mip map generation is enabled by default to provide better texturing quality for objects far away. You can disable mip map generation to improve performance; however, you may see a moire pattern for far away textures. In the <maya directory>\presets\HLSL11\examples\AutodeskUberShader.fxo file, set #define NumberOfMipMaps 1.
  • The dx11Shader node supports both uncompiled (.fx) and compiled (.fxo) effects. For large scenes and complex shaders, use only compiled effects.

Textures

  • Unsupported texture types are baked internally in Viewport 2.0. For better performance, avoid using unsupported textures (see Viewport 2.0 Limitations).

    If your scene contains 3d textures that are not natively supported by Viewport 2.0, you can avoid long baking times for these textures by using low bake resolution values in the Bake Resolution for Unsupported Texture Types settings of the Viewport 2.0 options.

    See Internal texture baking in Viewport 2.0.

  • Texture dimensions do not necessarily need to be a power of two (that is, 256, 512, 1024), nor do they need to be square. Textures with dimensions to the power of two do not necessarily provide any performance benefit.

Additional optimization tips

Work with particleSamplerInfo nodes

When working with the particleSamplerInfo node, for best performance, you should disconnect unnecessary per-particle attributes from the particle sampler and leave only the required per-particle attributes. If a large number of per-particle attributes are required, use DirectX 11 as your rendering engine rather than OpenGL. If you must use OpenGL, you can also use a high-end graphics card to increase the vertex texture co-ordinate count.

Related topics