nodebpy 520.22.0__tar.gz → 520.23.0__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- {nodebpy-520.22.0 → nodebpy-520.23.0}/PKG-INFO +1 -1
- {nodebpy-520.22.0 → nodebpy-520.23.0}/pyproject.toml +1 -1
- {nodebpy-520.22.0 → nodebpy-520.23.0}/src/nodebpy/export/codegen.py +12 -3
- {nodebpy-520.22.0 → nodebpy-520.23.0}/README.md +0 -0
- {nodebpy-520.22.0 → nodebpy-520.23.0}/src/nodebpy/__init__.py +0 -0
- {nodebpy-520.22.0 → nodebpy-520.23.0}/src/nodebpy/assets/__init__.py +0 -0
- {nodebpy-520.22.0 → nodebpy-520.23.0}/src/nodebpy/assets/__main__.py +0 -0
- {nodebpy-520.22.0 → nodebpy-520.23.0}/src/nodebpy/assets/_codegen.py +0 -0
- {nodebpy-520.22.0 → nodebpy-520.23.0}/src/nodebpy/assets/_library.py +0 -0
- {nodebpy-520.22.0 → nodebpy-520.23.0}/src/nodebpy/assets/_pipeline.py +0 -0
- {nodebpy-520.22.0 → nodebpy-520.23.0}/src/nodebpy/builder/__init__.py +0 -0
- {nodebpy-520.22.0 → nodebpy-520.23.0}/src/nodebpy/builder/_registry.py +0 -0
- {nodebpy-520.22.0 → nodebpy-520.23.0}/src/nodebpy/builder/_utils.py +0 -0
- {nodebpy-520.22.0 → nodebpy-520.23.0}/src/nodebpy/builder/accessor.py +0 -0
- {nodebpy-520.22.0 → nodebpy-520.23.0}/src/nodebpy/builder/asset.py +0 -0
- {nodebpy-520.22.0 → nodebpy-520.23.0}/src/nodebpy/builder/items.py +0 -0
- {nodebpy-520.22.0 → nodebpy-520.23.0}/src/nodebpy/builder/layout.py +0 -0
- {nodebpy-520.22.0 → nodebpy-520.23.0}/src/nodebpy/builder/mixins.py +0 -0
- {nodebpy-520.22.0 → nodebpy-520.23.0}/src/nodebpy/builder/node.py +0 -0
- {nodebpy-520.22.0 → nodebpy-520.23.0}/src/nodebpy/builder/socket.py +0 -0
- {nodebpy-520.22.0 → nodebpy-520.23.0}/src/nodebpy/builder/tree.py +0 -0
- {nodebpy-520.22.0 → nodebpy-520.23.0}/src/nodebpy/export/__init__.py +0 -0
- {nodebpy-520.22.0 → nodebpy-520.23.0}/src/nodebpy/export/diagram.py +0 -0
- {nodebpy-520.22.0 → nodebpy-520.23.0}/src/nodebpy/export/parity.py +0 -0
- {nodebpy-520.22.0 → nodebpy-520.23.0}/src/nodebpy/export/plot.py +0 -0
- {nodebpy-520.22.0 → nodebpy-520.23.0}/src/nodebpy/export/web_render.py +0 -0
- {nodebpy-520.22.0 → nodebpy-520.23.0}/src/nodebpy/lib/nodearrange/VENDORED.md +0 -0
- {nodebpy-520.22.0 → nodebpy-520.23.0}/src/nodebpy/lib/nodearrange/__init__.py +0 -0
- {nodebpy-520.22.0 → nodebpy-520.23.0}/src/nodebpy/lib/nodearrange/arrange/__init__.py +0 -0
- {nodebpy-520.22.0 → nodebpy-520.23.0}/src/nodebpy/lib/nodearrange/arrange/graph.py +0 -0
- {nodebpy-520.22.0 → nodebpy-520.23.0}/src/nodebpy/lib/nodearrange/arrange/ordering.py +0 -0
- {nodebpy-520.22.0 → nodebpy-520.23.0}/src/nodebpy/lib/nodearrange/arrange/ranking.py +0 -0
- {nodebpy-520.22.0 → nodebpy-520.23.0}/src/nodebpy/lib/nodearrange/arrange/realize.py +0 -0
- {nodebpy-520.22.0 → nodebpy-520.23.0}/src/nodebpy/lib/nodearrange/arrange/stacking.py +0 -0
- {nodebpy-520.22.0 → nodebpy-520.23.0}/src/nodebpy/lib/nodearrange/arrange/structs.py +0 -0
- {nodebpy-520.22.0 → nodebpy-520.23.0}/src/nodebpy/lib/nodearrange/arrange/sugiyama.py +0 -0
- {nodebpy-520.22.0 → nodebpy-520.23.0}/src/nodebpy/lib/nodearrange/arrange/x_coords.py +0 -0
- {nodebpy-520.22.0 → nodebpy-520.23.0}/src/nodebpy/lib/nodearrange/arrange/y_coords.py +0 -0
- {nodebpy-520.22.0 → nodebpy-520.23.0}/src/nodebpy/lib/nodearrange/config.py +0 -0
- {nodebpy-520.22.0 → nodebpy-520.23.0}/src/nodebpy/lib/nodearrange/utils.py +0 -0
- {nodebpy-520.22.0 → nodebpy-520.23.0}/src/nodebpy/nodes/__init__.py +0 -0
- {nodebpy-520.22.0 → nodebpy-520.23.0}/src/nodebpy/nodes/_mixins.py +0 -0
- {nodebpy-520.22.0 → nodebpy-520.23.0}/src/nodebpy/nodes/compositor/__init__.py +0 -0
- {nodebpy-520.22.0 → nodebpy-520.23.0}/src/nodebpy/nodes/compositor/assets.py +0 -0
- {nodebpy-520.22.0 → nodebpy-520.23.0}/src/nodebpy/nodes/compositor/color.py +0 -0
- {nodebpy-520.22.0 → nodebpy-520.23.0}/src/nodebpy/nodes/compositor/converter.py +0 -0
- {nodebpy-520.22.0 → nodebpy-520.23.0}/src/nodebpy/nodes/compositor/distort.py +0 -0
- {nodebpy-520.22.0 → nodebpy-520.23.0}/src/nodebpy/nodes/compositor/filter.py +0 -0
- {nodebpy-520.22.0 → nodebpy-520.23.0}/src/nodebpy/nodes/compositor/group.py +0 -0
- {nodebpy-520.22.0 → nodebpy-520.23.0}/src/nodebpy/nodes/compositor/input.py +0 -0
- {nodebpy-520.22.0 → nodebpy-520.23.0}/src/nodebpy/nodes/compositor/interface.py +0 -0
- {nodebpy-520.22.0 → nodebpy-520.23.0}/src/nodebpy/nodes/compositor/manual.py +0 -0
- {nodebpy-520.22.0 → nodebpy-520.23.0}/src/nodebpy/nodes/compositor/matte.py +0 -0
- {nodebpy-520.22.0 → nodebpy-520.23.0}/src/nodebpy/nodes/compositor/output.py +0 -0
- {nodebpy-520.22.0 → nodebpy-520.23.0}/src/nodebpy/nodes/compositor/vector.py +0 -0
- {nodebpy-520.22.0 → nodebpy-520.23.0}/src/nodebpy/nodes/geometry/__init__.py +0 -0
- {nodebpy-520.22.0 → nodebpy-520.23.0}/src/nodebpy/nodes/geometry/assets.py +0 -0
- {nodebpy-520.22.0 → nodebpy-520.23.0}/src/nodebpy/nodes/geometry/attribute.py +0 -0
- {nodebpy-520.22.0 → nodebpy-520.23.0}/src/nodebpy/nodes/geometry/color.py +0 -0
- {nodebpy-520.22.0 → nodebpy-520.23.0}/src/nodebpy/nodes/geometry/converter.py +0 -0
- {nodebpy-520.22.0 → nodebpy-520.23.0}/src/nodebpy/nodes/geometry/geometry.py +0 -0
- {nodebpy-520.22.0 → nodebpy-520.23.0}/src/nodebpy/nodes/geometry/grid.py +0 -0
- {nodebpy-520.22.0 → nodebpy-520.23.0}/src/nodebpy/nodes/geometry/group.py +0 -0
- {nodebpy-520.22.0 → nodebpy-520.23.0}/src/nodebpy/nodes/geometry/groups.py +0 -0
- {nodebpy-520.22.0 → nodebpy-520.23.0}/src/nodebpy/nodes/geometry/input.py +0 -0
- {nodebpy-520.22.0 → nodebpy-520.23.0}/src/nodebpy/nodes/geometry/interface.py +0 -0
- {nodebpy-520.22.0 → nodebpy-520.23.0}/src/nodebpy/nodes/geometry/manual.py +0 -0
- {nodebpy-520.22.0 → nodebpy-520.23.0}/src/nodebpy/nodes/geometry/output.py +0 -0
- {nodebpy-520.22.0 → nodebpy-520.23.0}/src/nodebpy/nodes/geometry/texture.py +0 -0
- {nodebpy-520.22.0 → nodebpy-520.23.0}/src/nodebpy/nodes/geometry/utilities.py +0 -0
- {nodebpy-520.22.0 → nodebpy-520.23.0}/src/nodebpy/nodes/geometry/vector.py +0 -0
- {nodebpy-520.22.0 → nodebpy-520.23.0}/src/nodebpy/nodes/geometry/zone.py +0 -0
- {nodebpy-520.22.0 → nodebpy-520.23.0}/src/nodebpy/nodes/shader/__init__.py +0 -0
- {nodebpy-520.22.0 → nodebpy-520.23.0}/src/nodebpy/nodes/shader/assets.py +0 -0
- {nodebpy-520.22.0 → nodebpy-520.23.0}/src/nodebpy/nodes/shader/color.py +0 -0
- {nodebpy-520.22.0 → nodebpy-520.23.0}/src/nodebpy/nodes/shader/converter.py +0 -0
- {nodebpy-520.22.0 → nodebpy-520.23.0}/src/nodebpy/nodes/shader/grid.py +0 -0
- {nodebpy-520.22.0 → nodebpy-520.23.0}/src/nodebpy/nodes/shader/group.py +0 -0
- {nodebpy-520.22.0 → nodebpy-520.23.0}/src/nodebpy/nodes/shader/input.py +0 -0
- {nodebpy-520.22.0 → nodebpy-520.23.0}/src/nodebpy/nodes/shader/manual.py +0 -0
- {nodebpy-520.22.0 → nodebpy-520.23.0}/src/nodebpy/nodes/shader/output.py +0 -0
- {nodebpy-520.22.0 → nodebpy-520.23.0}/src/nodebpy/nodes/shader/script.py +0 -0
- {nodebpy-520.22.0 → nodebpy-520.23.0}/src/nodebpy/nodes/shader/shader.py +0 -0
- {nodebpy-520.22.0 → nodebpy-520.23.0}/src/nodebpy/nodes/shader/texture.py +0 -0
- {nodebpy-520.22.0 → nodebpy-520.23.0}/src/nodebpy/nodes/shader/vector.py +0 -0
- {nodebpy-520.22.0 → nodebpy-520.23.0}/src/nodebpy/types.py +0 -0
|
@@ -812,6 +812,15 @@ def _make_var(label: str, counter: dict[str, int]) -> str:
|
|
|
812
812
|
return f"{base}_{counter[base]}"
|
|
813
813
|
|
|
814
814
|
|
|
815
|
+
def _node_var_label(node) -> str:
|
|
816
|
+
"""The stem for a node's generated variable name. A group node's
|
|
817
|
+
``bl_label`` is just "Group", so it reads as its group's name instead
|
|
818
|
+
(``inverse_mass = InverseMass()``)."""
|
|
819
|
+
if node.bl_idname in _GROUP_BASES and node.node_tree is not None:
|
|
820
|
+
return node.node_tree.name
|
|
821
|
+
return node.bl_label or "node"
|
|
822
|
+
|
|
823
|
+
|
|
815
824
|
# ---------------------------------------------------------------------------
|
|
816
825
|
# Graph utilities
|
|
817
826
|
# ---------------------------------------------------------------------------
|
|
@@ -1203,7 +1212,7 @@ class EmitContext:
|
|
|
1203
1212
|
vector feeding ``vec.x`` / ``vec.y``). The assignment is queued on
|
|
1204
1213
|
``pending_lines`` and flushed before the consuming statement.
|
|
1205
1214
|
"""
|
|
1206
|
-
label = link.from_socket.name or link.from_node
|
|
1215
|
+
label = link.from_socket.name or _node_var_label(link.from_node)
|
|
1207
1216
|
var = _make_var(label, self.counter)
|
|
1208
1217
|
self.pending_lines.append(f" {var} = {expr.render()}")
|
|
1209
1218
|
ref = Ref(var)
|
|
@@ -4491,7 +4500,7 @@ def _emit_tree(node_tree, collector: _GroupCollector) -> _TreeEmission:
|
|
|
4491
4500
|
f"Cannot generate code: {message}. Register an emitter "
|
|
4492
4501
|
"with register_emitter() or pass strict=False."
|
|
4493
4502
|
)
|
|
4494
|
-
var = _make_var(node
|
|
4503
|
+
var = _make_var(_node_var_label(node), ctx.counter)
|
|
4495
4504
|
if not ctx.outgoing.get(name):
|
|
4496
4505
|
var = "_" + var
|
|
4497
4506
|
ctx.var_map[name] = _Val(Ref(var))
|
|
@@ -4577,7 +4586,7 @@ def _emit_tree(node_tree, collector: _GroupCollector) -> _TreeEmission:
|
|
|
4577
4586
|
consumed_out_links.add(id(link))
|
|
4578
4587
|
continue
|
|
4579
4588
|
|
|
4580
|
-
var = _make_var(node
|
|
4589
|
+
var = _make_var(_node_var_label(node), ctx.counter)
|
|
4581
4590
|
# A node created purely for its side effect (a gizmo, a dangling
|
|
4582
4591
|
# node) is never referenced again — prefix its variable so the
|
|
4583
4592
|
# generated module passes lint (F841).
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|