A scripting API for Blender's Geometry Nodes:
Go to file
Adam P 8a17643d8b
Fix some cases of node name collisions
Some compositor and texture nodes share names with the geometry nodes versions. This change sorts them so that the geometry ones are registered last, overriding the incorrect ones. The Math node is handled separately, because here the ShaderNodeMath is the correct one to use, for some reason.
2023-04-06 17:42:59 +02:00
.github/workflows Fix actions 2022-12-09 16:03:40 -05:00
api Fix some cases of node name collisions 2023-04-06 17:42:59 +02:00
book Document named outputs syntax 2022-12-09 15:55:32 -05:00
docs Keep docs and typeshed folders so files can be created 2022-12-02 19:23:10 -05:00
examples Update examples to use generated enums 2022-11-17 13:18:08 -05:00
typeshed Keep docs and typeshed folders so files can be created 2022-12-02 19:23:10 -05:00
.gitignore Keep docs and typeshed folders so files can be created 2022-12-02 19:23:10 -05:00
LICENSE Create LICENSE 2022-11-13 14:53:08 -05:00
README.md Update for Blender 3.5 release 2023-04-01 16:33:48 -04:00
__init__.py Bump version to 0.1.2 2022-12-02 19:23:48 -05:00
absolute_path.py Add default argument value support 2022-11-14 18:31:26 -05:00
external.py Add helpers for working with external files and docs 2022-11-13 18:49:09 -05:00
preferences.py Add helpers for working with external files and docs 2022-11-13 18:49:09 -05:00

README.md

Geometry Script wordmark

A scripting API for Blender's Geometry Nodes:

from geometry_script import *

@tree("Repeat Grid")
def repeat_grid(geometry: Geometry, width: Int, height: Int):
    g = grid(
        size_x=width, size_y=height,
        vertices_x=width, vertices_y=height
    ).mesh.mesh_to_points()
    return g.instance_on_points(instance=geometry)

Generated node tree

Installation

  1. Download the source code
  2. Open Blender > Preferences > Add-ons
  3. Choose Install... and select the downloaded ZIP file

Or you can get it from the Blender Market.

What is Geometry Script?

Geometry Script is a robust yet easy to use Python API for creating Geometry Nodes with code.

At a certain point, Geometry Node trees become unmanagably large. Creating node trees in Python enables quicker editing and reorganization of large, complex trees.

Geometry Script has all of the performance and capabilities of Geometry Nodes, but in a more managable format. The scripts are converted directly to Geometry Node trees making them easy to tweak for others unfamiliar with scripting.

Documentation

Read the documentation for more information on installation, syntax, and tutorials.