This is a pretty simple script that mimics what you can already do in Terragen on a node by node basis via the "Copy/paste coordinates" button on many parameters. However, there are a couple of advantages to using the script.
First, there's no UI. Second, you can select multiple nodes in the Node Network and set their xyz coordinates all at once. The nodes don't have to be of the same class either. For example, you can select a Simple Shape shader node which uses the Position parameter for its xyz coordinates and select a TGO reader node which uses the Translate parameter for its xyz coordinates. Both parameters will be updated with the xyz coordinate values in the clipboard.
You need two things to use the script; valid xyz coordinates in the clipboard and at least one selected node. To add the xyz coordinates to the clipboard, simply right click in the 3D Preview and select "
Copy Coordinates". With some nodes selected in the Node Network, run the script.
"Running the script" currently means to double click the Python script filename from wherever you've saved it to disk on your computer. In an upcoming post I'll show you a couple of ways to simplify the execution of a script, so running it will be more at your fingertips.
Teaser alert, this script is very helpful when used in conjunction with another script that I'll be posting soon. One that has more artistic merits than utilitarian.
This script is now included with the
redmaw-tg-toolkit repository.
Click the link below for download and installation information for the entire toolkit.
https://github.com/RedMawVFX/redmaw-tg-toolkitOr, click the link below to go directly to the tg-copy-coords-to-selected folder in the toolkit.
https://github.com/RedMawVFX/redmaw-tg-toolkit/tree/main/scripts/tg-copy-coords-to-selected