I'm not sure if this is the right section to post this in, but I'm looking to set ‘selection highlight’ or ‘selected objects’ via Python for a viewer state.
First question, is this possible? Most of the selection methods I found in the docs took Geometry as an argument, I didn't come across anything that dealt with LOPs / stages.
If it's not possible, is there another viewer state method for ‘coloring’ or ‘overlaying’ geometry that I could use instead?
Thanks for any direction you can provide, even if it's vague
Viewer State: Set Solaris viewport selection via Python
4238 3 2- blented
- Member
- 61 posts
- Joined: 10月 2013
- Offline
- malexander
- スタッフ
- 5212 posts
- Joined: 7月 2005
- Offline
- blented
- Member
- 61 posts
- Joined: 10月 2013
- Offline
Awesome, thanks for the quick reply.
Here's a link to the docs page:
https://www.sidefx.com/docs/houdini/hom/hou/SceneViewer.html [www.sidefx.com]
Inside a viewer state it's as easy as:
The selection highlight updates and also doesn't trigger an undo which is great for my use case
Here's a link to the docs page:
https://www.sidefx.com/docs/houdini/hom/hou/SceneViewer.html [www.sidefx.com]
Inside a viewer state it's as easy as:
self.sceneViewer.setCurrentSceneGraphSelection(['/scene/toy_001'])
The selection highlight updates and also doesn't trigger an undo which is great for my use case
Grant Miller
VFX Supervisor
Ingenuity Studios
VFX Supervisor
Ingenuity Studios
- blented
- Member
- 61 posts
- Joined: 10月 2013
- Offline
One minor issue, when I set the viewport selection via python, if I press Alt to tumble the selection highlighting disappears. If I mouse out of the viewport then back over the selection will come back. Bug? Seems to work w/ the default selection tools just not pythonically.
Grant Miller
VFX Supervisor
Ingenuity Studios
VFX Supervisor
Ingenuity Studios
-
- Quick Links