The knob which holds the tree of paint elements (Layers, Shapes and
Strokes).
Most operations are performed on the tree itself, or its elements,
rather than through the knob. You can get the root of the tree through
the knob's rootLayer property, or you can get straight to a specific
element using the toElement() method.
Creating any new shapes, strokes or layers will require you to pass in
a reference to the knob, so it's worth storing the reference in a
variable.
|
|
|
|
|
__setattr__(...)
x.__setattr__('name', value) <==> x.name = value |
|
|
None
|
changed(self)
Call this after performing updates on the tree, to tell it that it's
been updated. |
|
|
[selectedObjects]
|
getSelected(self)
Returns list of all selected items in a curve knob As an example, say
you have a Bezier curve selected,the following will return 'Bezier1'
>>> curveKnob = nuke.toNode('RotoPaint1)['curves']
>>> selected = curveKnob.getSelected() >>>
selected[0].name |
|
|
Element
|
toElement(self,
path)
Takes a path which identifies a particular element in the curve tree
and returns the corresponding Layer, Stroke or Shape object. |
|
|
Inherited from nuke.Knob :
Class ,
__init__ ,
__new__ ,
clearAnimated ,
clearFlag ,
critical ,
debug ,
enabled ,
error ,
fromScript ,
fullyQualifiedName ,
getDerivative ,
getFlag ,
getIntegral ,
getKeyIndex ,
getKeyList ,
getKeyTime ,
getNthDerivative ,
getNumKeys ,
getValue ,
getValueAt ,
hasExpression ,
isAnimated ,
isKey ,
isKeyAt ,
label ,
name ,
node ,
removeKey ,
removeKeyAt ,
setAnimated ,
setEnabled ,
setExpression ,
setFlag ,
setLabel ,
setName ,
setTooltip ,
setValue ,
setValueAt ,
setVisible ,
toScript ,
tooltip ,
value ,
visible ,
warning
Inherited from object :
__format__ ,
__hash__ ,
__reduce__ ,
__reduce_ex__ ,
__repr__ ,
__sizeof__ ,
__str__ ,
__subclasshook__
|