I wanted a way to carry a shader inside a pyfile, to keep this self contained. This will be a pretty crazy example of how to script a shader from scratch. Writing a script that converts an existing shader node_tree ( material ) is possible and could be written with a cascading recursion into the node_tree.
As soon as the shader starts to get complicated it's probably best to use a .blend and append materials from it instead.
As soon as the shader starts to get complicated it's probably best to use a .blend and append materials from it instead.