Python: Return list of selected compositing nodes

Discussions concerning programming of SOFTIMAGE©
Post Reply
TwirlySocrates
Posts: 9
Joined: 15 Jan 2014, 02:47

Re: Python: Return list of selected compositing nodes

Post by TwirlySocrates » 15 Jan 2014, 22:39

Thanks for your sample code... would you have anything that works in Soft 2012?
I tried using the attribute "selection" and it's only returning 'None'

User avatar
csaez
Posts: 253
Joined: 09 Jul 2012, 15:31
Skype: csaezmargotta
Location: Sydney, Australia
Contact:

Re: Python: Return list of selected compositing nodes

Post by csaez » 15 Jan 2014, 23:12

TwirlySocrates wrote:I tried using the attribute "selection" and it's only returning 'None'
I know, forget about that snippet, it was just a shot in the dark hoping to find some consistency with similar views, but it doesn't work.

EricTRocks
Moderator
Posts: 754
Joined: 25 Nov 2009, 01:41
Contact:

Re: Python: Return list of selected compositing nodes

Post by EricTRocks » 15 Jan 2014, 23:13

As Luc-Eric said, the selected nodes view attribute was only added in 2014. Prior versions, you're out of luck.
Eric Thivierge
Lead Kraken Developer, Fabric Engine
http://fabric-engine.github.io/Kraken

TwirlySocrates
Posts: 9
Joined: 15 Jan 2014, 02:47

Re: Python: Return list of selected compositing nodes

Post by TwirlySocrates » 15 Jan 2014, 23:17

EricTRocks wrote:As Luc-Eric said, the selected nodes view attribute was only added in 2014. Prior versions, you're out of luck.
Alrighty. Thank you.

luceric
Posts: 1251
Joined: 22 Jun 2009, 00:08

Re: Python: Return list of selected compositing nodes

Post by luceric » 16 Jan 2014, 00:11

so.. why do you want that selection, what were you going to do with it

TwirlySocrates
Posts: 9
Joined: 15 Jan 2014, 02:47

Re: Python: Return list of selected compositing nodes

Post by TwirlySocrates » 16 Jan 2014, 00:24

luceric wrote:so.. why do you want that selection, what were you going to do with it
I'm doing a lot of repetitive tasks in comp.

Some of these tasks would include:
* Arrange selected nodes in an evenly spaced horizontal line.
* Comp selected nodes together using "over" nodes at .5 opacity
* Comp selected nodes together using "over" nodes at 1.0 opacity

It's easy to do by hand, but when you have to do it all day, it would be easier to script.

Post Reply

Who is online

Users browsing this forum: No registered users and 17 guests