Trivially make long math chains using a simple Python expression.
This supports the main builtin node editors in blender: Shader Editor, Geometry Node Editor, Texture Node Editor, Compositor
In the text box that appears, type in a mathematical expression that you want to evaluate, for example, sin(x + 64) % (y ** 14 + 10). Accept the dialogue and a node tree will be generated with math nodes.
Mathematical operators you would expect to work are supported, including:
And all other mathematical functions in the Math node is supported.
Edit preferences lookups as per guidelines
This extension does not require special permissions.
Please note that this add-on works only in Shader editor, so that it satisfies "no surprises" principle for add-ons.
Also, there are numerous python errors when simply writing expression and pressing create. First ever attempt. This is expression I used
x + (24 / 2) * 3
Please note that this add-on works only in Shader editor, so that it satisfies "no surprises" principle for add-ons.
I have updated it so they are supported in the Geo nodes, the compositor, and texture nodes
x + (24 / 2) * 3
Interesting, such a simple expression shouldnt be causing an error🤔 could you post the error if you still get it with the latest release? Works as intended for me. (I also added a debug prints option in the add-on preferences)
Using __name__
to lookup add-on preferences is no longer valid,
see: https://docs.blender.org/manual/en/dev/advanced/extensions/addons.html#user-preferences-and-package
Sign in to comment.
Ready for review