Every time I use "Add selected to layer"
ORA panels show in the Stack/Settings
Invisible is set to 0
Show hidden lines is set to -1
Show backfaces is set to -1
In this case, three Cubes were selected
When I use "Remove the Layer"
The object's Object Render Attributes node(s) are deleted
Also, Lights and Cameras, in addition to the above, the ORA Default aspect is being exported out
Workspace Layers v4
- clintonman
- Captain
- Posts: 5430
- Joined: 21 May 2009, 21:08
- Type the number ten into the box: 0
- Location: California
- Contact:
Re: Workspace Layers v4
ORA panels show in Stack - must be missing your special commands from the CloseORASettings node that cleans it up, thanks.trueBlue wrote: ↑06 May 2021, 12:24 Every time I use "Add selected to layer"
ORA panels show in the Stack/Settings
Invisible is set to 0
Show hidden lines is set to -1
Show backfaces is set to -1
In this case, three Cubes were selected
Add selected to Layer.png
When I use "Remove the Layer"
The object's Object Render Attributes node(s) are deleted
Also, Lights and Cameras, in addition to the above, the ORA Default aspect is being exported out
I see the problem with Show hidden lines and backfaces. I check for a valid connector and then forgot to set it based on the layer setting.
The invisible should be set according to the layer settings.
Remove Layer ORA are deleted was the same way in workspace layers3. I based it on the fact that bare tS meshes don't have ORA nodes. Bare tS cameras and lights are in layer1 so they get moved to layer1 when the layer they occupy is removed.
I don't see the exported ORA as a problem for lights and cameras, could be some disadvantage I don't know about, but I think the RsStackView.SetPanelExportInfo command might be used to "un-export" it. I'll let you know what I find, thanks again.
Re: Workspace Layers v4
One disadvantage of deleting the ORA node would be when a user has set any of the options in the ORA nodeRemove Layer ORA are deleted was the same way in workspace layers3. I based it on the fact that bare tS meshes don't have ORA nodes. Bare tS cameras and lights are in layer1 so they get moved to layer1 when the layer they occupy is removed.
Like Cast shadows and or Receive shadows
Maybe you could just set the Layer index to 0
I don't see the exported ORA as a problem for lights and cameras, could be some disadvantage I don't know about, but I think the RsStackView.SetPanelExportInfo command might be used to "un-export" it. I'll let you know what I find, thanks again.
Add
&& (!Node.IsCamera(cursel) || !Node.IsLight(cursel)
Re: Workspace Layers v4
After reading your new UU Doc, I noticed where you mention that Booleans remove the ORA
I have a working Booleans widget that Saves the ORA to the RsData folder, runs the Boolean tool, then Loads the saved ORA back into the First Selected Object Save ORA
Load ORA
This is working great in Workspace Layers 4, but is limited to the First Selected Object
.
.
This is not going to work with Groups!
Do you think you could make it work for Groups and or whatever else is needed?
Edit: It looks like Booleans remove Group's ORA too, so this might Work!
Thoughts?
I have a working Booleans widget that Saves the ORA to the RsData folder, runs the Boolean tool, then Loads the saved ORA back into the First Selected Object Save ORA
Code: Select all
if(Node.Exists(Node.FirstSelected() + '/Object Render Attributes')) {
var fSel = Node.FirstSelected()
Node.ConRemove(fSel, 'RenderAttributes')
RsFileIO.SaveObject(System.GetMainDir() + '\\RS Data\\Object Render Attributes.RsObj', fSel + '/Object Render Attributes')
Node.Delete(fSel + '/Object Render Attributes')
Code: Select all
var fSel = Node.FirstSelected()
RsFileIO.LoadObject(System.GetMainDir() + '\\RS Data\\Object Render Attributes.RsObj', fSel + '/')
Node.ExportConnector(fSel + "/Object Render Attributes", "RenderAttributes", "", 1, 1)
.
This is not going to work with Groups!
Do you think you could make it work for Groups and or whatever else is needed?
Edit: It looks like Booleans remove Group's ORA too, so this might Work!
Thoughts?
- clintonman
- Captain
- Posts: 5430
- Joined: 21 May 2009, 21:08
- Type the number ten into the box: 0
- Location: California
- Contact:
Re: Workspace Layers v4
Haven't had a chance to test it. Only thought is don't forget to test the other boolean option, "not flatten" or whatever it's called and test on Subdivision objects.