In the scope of this user guide, it’s not possible to go into detail with Python and all the scripts available. However, there are several sources of more information that you may find useful if you need help using Python.
In the Python Developer’s Guide, you’ll find everything you need in terms of Python examples and ways of using Python for various purposes in Nuke. You’ll find the Python Developer’s Guide when you click Help > Documentation > Python Developers Guide in Nuke.
You may also want to read the Nuke Python API reference documentation under Help > Documentation > PythonScriptingReference.
We only described a few examples of Python scripts in this chapter, but there are more. You can find them in the following location:
• On Windows:
drive letter:\Program Files\Nuke9.0v10\plugins\nukescripts or
drive letter:\Program Files (x86)\Nuke9.0v10\plugins\nukescripts
• On Mac OS X:
/Applications/Nuke9.0v10/Nuke9.0v10.app/Contents/MacOS/plugins/nukescripts
• On Linux:
/usr/local/Nuke9.0v10/plugins/nukescripts
To view an example, select one of the .py files and open it in any text editor.
Possibly the quickest way of getting help on the available commands is to enter the following in the Script Editor:
help (nuke)
This statement lists many of the available Python commands in an alphabetical order together with their descriptions.
You can also get help on more specific things. For example, the following statement gives you a description of what the setValue() method does:
help (nuke.Knob.setValue)
To read more about Python, check out its documentation, or interact with other Python users. Visit the Python programming language official website at http://www.python.org/.
|