ScriptSpot home

Forum topic · General Scripting

Toggle Viewport Default Lighting in script

By markbola · 2009-01-20

Description

Hi,

I am trying to set the default viewport lighting to on or off and also set the 1 or 2 lights option but cannot seem to locate the correct method of doing it?

I thought it would be in the viewport class but nothing there? Does anybody know?

Cheers for your help.

Comments (2)
markbola

cheers for the speedy reply,

Ah that was recording the ctrl + L keystroke.

The problem with this is I do not have the current state of the default lighting. I need to parse multiple files with snapshots of objects with .fx materials on them. .fx materials do not render so a viewport snapshot is done instead. My main issue is that all the files have multiple light settings so that's the reason of needing to set the default lighting with 1 light only.

dimwalker

Here is a command for turnung on/off default viewport lighting:

max default lighting toggle

found it with macroRecorder 8)