Chris I believe this is down the right path. What I am trying to do find a roto spline by selecting it in the viewer. In some cases we may have hundreds of roto splines and may not know what that spline is named or where it lives in the node graph. We would like to be able to select in the node graph, the spline that is selected in the viewer.
The statement you supplied gives the name of the node plugged directly into the active viewer. Thanks, Nick On Jun 6, 2011, at 2:07 AM, Chris Bevan <[email protected]> wrote: > Hi Nickolas, > > Sounds like the following should do what you're after: > > v = nuke.activeViewer() > if v.activeInput() is not None: > print v.node().input(v.activeInput()).name() > > Cheers, > > - Chris > > On 04/06/11 19:47, Nickolas Stevens wrote: >> Does anyone know how to return the name of a node selected in the viewer but >> not in the node graph? >> >> For instance if I have a bezier selected in the viewer, is there a simple >> way to find the name of that node? >> >> The only solution I've found so far is to show the bezier's panel when the >> spline is manipulated. >> >> >> def bezierSearch(): >> nuke.showDag(nuke.thisNode()) >> >> nuke.addKnobChanged(bezierSearch, nodeClass = 'Bezier') >> >> >> The biggest issue I have with this solution, is that it is always active. I >> need to be able to call it at will and it involves a change being made to >> the node in question. >> >> Anyone have ideas on this one?_______________________________________________ >> Nuke-python mailing list >> [email protected], http://forums.thefoundry.co.uk/ >> http://support.thefoundry.co.uk/cgi-bin/mailman/listinfo/nuke-python > > > -- > Chris Bevan, Senior Software Engineer > The Foundry, 6th Floor, The Communications Building > 48 Leicester Square, London, WC2H 7LT > Tel: +44 (0)20 7968 6828 | Fax: +44 (0)20 7930 8906 > Web: www.thefoundry.co.uk > > The Foundry Visionmongers Ltd > Registered in England and Wales No: 4642027 > > _______________________________________________ > Nuke-python mailing list > [email protected], http://forums.thefoundry.co.uk/ > http://support.thefoundry.co.uk/cgi-bin/mailman/listinfo/nuke-python _______________________________________________ Nuke-python mailing list [email protected], http://forums.thefoundry.co.uk/ http://support.thefoundry.co.uk/cgi-bin/mailman/listinfo/nuke-python
