View Full Version : Problem in lighting display
I want to select specific lights to display effecting
So I write this mel code
select -r directionalLight1 ;
select -tgl pointLight1 ;
select -tgl directionalLight2 ;
select -tgl spotLight1 ;
modelEditor -e -dl active modelPanel4;
But when click or press in any place in my project scense file ,the lights deselected so the effecting of lights removed
How solve this problem ????
Plzzzzzzzzzzzz help me asap :(
11-23-2012, 09:01 PM
Not completely sure I understand your problem:
You have a scene and lights in them. You want to keep them selected as a means of highlighting to the user which lights are active?
If so, then there's a couple ways I can think of doing this, both of which are kind of hacky.
1. Add a scriptJob that monitors SelectionChanged event and always ensure those lights are on the selection list.
2. The reason they deselect is because by default all the tools are selection based tools. You could optionally write your own context, set your tool to that context and have it ignore mouse clicks so that nothing gets deselected on clicks in the screen.
3. I would have actually suggested this as a first option, but in testing it, it doesn't look like it actually works. I would have suggested originally to use the Drawing Overrides on the light to configure the wireframe color and state. But it seems like the overrides don't work on the light's wireframe.
Very Thans , it well work using modelEditor -e -dl selected modelPanel4;
not active :)
11-24-2012, 06:28 PM
This thread has been automatically closed as it remained inactive for 12 months. If you wish to continue the discussion, please create a new thread in the appropriate forum.
vBulletin v3.0.5, Copyright ©2000-2013, Jelsoft Enterprises Ltd.