Renderers

Renderers is a Structure of systemGlobals. It lets the user assign renderer class instances to the current, production, Material Editor, and activeShade renderer:

renderers.current

Gets/Sets the current renderer.

renderers.production

Gets/Sets the production renderer.

renderers.activeShade

Gets/Sets the activeShade renderer. Only renderers whose supportsActiveShade property is true can be set as the activeShade renderer.

renderers.medit_locked

Controls the state of the "Lock To Current Renderer" checkbutton next to the Material Editor slot in the Common tab > Assign Renderer rollout in the Render Scene dialog. When set to True , the Production Renderer will be used automatically by the Material Editor. When set to False , the Material Editor renderer can be set independently from the Production Renderer.

renderers.medit

Gets/sets the Material Editor renderer.

renderers.renderDialogMode

Gets/sets the Render Dialog Mode.

Possible values are:

#production

#activeShade

Available in 3ds Max 2016 and higher.

renderers.renderButtonText

Currently returns "", cannot be set.

Available in 3ds Max 2016 and higher.

renderers.target

Gets/sets the Render Setup dialog's Target mode.

Possible values are:

"local" - render locally

"cloud" - render on the Cloud

Available in 3ds Max 2016 and higher.

renderers.GetDraftRenderer()

Returns the draft renderer.

While the draft renderer is not exposed or used by 3ds Max anymore since version 6, it is possible that a renderer is assigned as the draft renderer. If that renderer is an instance of a 3 rd party plug-in and you load the scene file on a computer without that plug-in installed, you will get missing plug-in messages and no way to get rid of them.

Available in 3ds Max 2008 and higher. Previously, available in Avguard Extensions.

Note:

Getting the draft renderer will cause a new default renderer to be created and set as the draft renderer if there is no current draft renderer.

renderers.ClearDraftRenderer()

Removes the draft renderer if present.

While the draft renderer is not exposed or used by 3ds Max anymore since version 6, it is possible that a renderer is assigned as the draft renderer. If that renderer is an instance of a 3 rd party plug-in and you load the scene file on a computer without that plug-in installed, you will get missing plug-in messages and no way to get rid of them.

Available in 3ds Max 2008 and higher. Previously, available in Avguard Extensions.

Renderer class instances can be created by MAXScript. They have a couple of common read-only properties that is used to determine if the renderer can perform certain special tasks such as, ActiveShade rendering and TextureBaking.

RendererClass Instances Common Properties:

<RendererClassInstance>.supportsActiveShade

Returns true if the renderer can be used as ActiveShade renderer, false otherwise. Read-only.

<RendererClassInstance>.supportsTexureBaking

Returns true if the renderer supports Texture Baking, false otherwise. Read-only.

To acquire a list of all installed renderers on a specific system, you can access the .classes property of the RendererClass MAXSuperClass.

EXAMPLE

   RendererClass.classes
   -->#(Default_Scanline_Renderer, VUE_File_Renderer, mental_ray_Renderer, Missing_Renderer)
   --You can assign a new renderer class to the current renderer
   renderers.current = RendererClass.classes[2]()
   -->VUE_File_Renderer:VUE_File_Renderer

Material/Map Renderer Compatibility Method:

areMtlAndRendererCompatible {<mtlbase> | <maxclass>} [ renderer:{<renderer> | <maxclass>} ]

Returns true if the material/texturemap and renderer are compatible. Material/texturemap and renderer can be specified as instances or MAXClasses. If the renderer is not specified, the current renderer is tested.

EXAMPLE

   --Check Mental_Ray material against Scanline Renderer
   --They are not compatible!
   theMat = Mental_Ray()
   -->mental_ray:mental_ray
   theRenderer = Default_Scanline_Renderer()
   -->Default_Scanline_Renderer:Default_Scanline_Renderer
   areMtlAndRendererCompatible theMat renderer:theRenderer
   -->false
   --Check a Standard material against Scanline Renderer
   --They are compatible!
   theMat = Standard()
   -->Standardmaterial:Standard
   areMtlAndRendererCompatible theMat renderer:theRenderer
   -->true