nodebpy 520.22.0__tar.gz → 520.24.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.24.0}/PKG-INFO +1 -1
- {nodebpy-520.22.0 → nodebpy-520.24.0}/pyproject.toml +1 -1
- {nodebpy-520.22.0 → nodebpy-520.24.0}/src/nodebpy/export/codegen.py +25 -5
- {nodebpy-520.22.0 → nodebpy-520.24.0}/README.md +0 -0
- {nodebpy-520.22.0 → nodebpy-520.24.0}/src/nodebpy/__init__.py +0 -0
- {nodebpy-520.22.0 → nodebpy-520.24.0}/src/nodebpy/assets/__init__.py +0 -0
- {nodebpy-520.22.0 → nodebpy-520.24.0}/src/nodebpy/assets/__main__.py +0 -0
- {nodebpy-520.22.0 → nodebpy-520.24.0}/src/nodebpy/assets/_codegen.py +0 -0
- {nodebpy-520.22.0 → nodebpy-520.24.0}/src/nodebpy/assets/_library.py +0 -0
- {nodebpy-520.22.0 → nodebpy-520.24.0}/src/nodebpy/assets/_pipeline.py +0 -0
- {nodebpy-520.22.0 → nodebpy-520.24.0}/src/nodebpy/builder/__init__.py +0 -0
- {nodebpy-520.22.0 → nodebpy-520.24.0}/src/nodebpy/builder/_registry.py +0 -0
- {nodebpy-520.22.0 → nodebpy-520.24.0}/src/nodebpy/builder/_utils.py +0 -0
- {nodebpy-520.22.0 → nodebpy-520.24.0}/src/nodebpy/builder/accessor.py +0 -0
- {nodebpy-520.22.0 → nodebpy-520.24.0}/src/nodebpy/builder/asset.py +0 -0
- {nodebpy-520.22.0 → nodebpy-520.24.0}/src/nodebpy/builder/items.py +0 -0
- {nodebpy-520.22.0 → nodebpy-520.24.0}/src/nodebpy/builder/layout.py +0 -0
- {nodebpy-520.22.0 → nodebpy-520.24.0}/src/nodebpy/builder/mixins.py +0 -0
- {nodebpy-520.22.0 → nodebpy-520.24.0}/src/nodebpy/builder/node.py +0 -0
- {nodebpy-520.22.0 → nodebpy-520.24.0}/src/nodebpy/builder/socket.py +0 -0
- {nodebpy-520.22.0 → nodebpy-520.24.0}/src/nodebpy/builder/tree.py +0 -0
- {nodebpy-520.22.0 → nodebpy-520.24.0}/src/nodebpy/export/__init__.py +0 -0
- {nodebpy-520.22.0 → nodebpy-520.24.0}/src/nodebpy/export/diagram.py +0 -0
- {nodebpy-520.22.0 → nodebpy-520.24.0}/src/nodebpy/export/parity.py +0 -0
- {nodebpy-520.22.0 → nodebpy-520.24.0}/src/nodebpy/export/plot.py +0 -0
- {nodebpy-520.22.0 → nodebpy-520.24.0}/src/nodebpy/export/web_render.py +0 -0
- {nodebpy-520.22.0 → nodebpy-520.24.0}/src/nodebpy/lib/nodearrange/VENDORED.md +0 -0
- {nodebpy-520.22.0 → nodebpy-520.24.0}/src/nodebpy/lib/nodearrange/__init__.py +0 -0
- {nodebpy-520.22.0 → nodebpy-520.24.0}/src/nodebpy/lib/nodearrange/arrange/__init__.py +0 -0
- {nodebpy-520.22.0 → nodebpy-520.24.0}/src/nodebpy/lib/nodearrange/arrange/graph.py +0 -0
- {nodebpy-520.22.0 → nodebpy-520.24.0}/src/nodebpy/lib/nodearrange/arrange/ordering.py +0 -0
- {nodebpy-520.22.0 → nodebpy-520.24.0}/src/nodebpy/lib/nodearrange/arrange/ranking.py +0 -0
- {nodebpy-520.22.0 → nodebpy-520.24.0}/src/nodebpy/lib/nodearrange/arrange/realize.py +0 -0
- {nodebpy-520.22.0 → nodebpy-520.24.0}/src/nodebpy/lib/nodearrange/arrange/stacking.py +0 -0
- {nodebpy-520.22.0 → nodebpy-520.24.0}/src/nodebpy/lib/nodearrange/arrange/structs.py +0 -0
- {nodebpy-520.22.0 → nodebpy-520.24.0}/src/nodebpy/lib/nodearrange/arrange/sugiyama.py +0 -0
- {nodebpy-520.22.0 → nodebpy-520.24.0}/src/nodebpy/lib/nodearrange/arrange/x_coords.py +0 -0
- {nodebpy-520.22.0 → nodebpy-520.24.0}/src/nodebpy/lib/nodearrange/arrange/y_coords.py +0 -0
- {nodebpy-520.22.0 → nodebpy-520.24.0}/src/nodebpy/lib/nodearrange/config.py +0 -0
- {nodebpy-520.22.0 → nodebpy-520.24.0}/src/nodebpy/lib/nodearrange/utils.py +0 -0
- {nodebpy-520.22.0 → nodebpy-520.24.0}/src/nodebpy/nodes/__init__.py +0 -0
- {nodebpy-520.22.0 → nodebpy-520.24.0}/src/nodebpy/nodes/_mixins.py +0 -0
- {nodebpy-520.22.0 → nodebpy-520.24.0}/src/nodebpy/nodes/compositor/__init__.py +0 -0
- {nodebpy-520.22.0 → nodebpy-520.24.0}/src/nodebpy/nodes/compositor/assets.py +0 -0
- {nodebpy-520.22.0 → nodebpy-520.24.0}/src/nodebpy/nodes/compositor/color.py +0 -0
- {nodebpy-520.22.0 → nodebpy-520.24.0}/src/nodebpy/nodes/compositor/converter.py +0 -0
- {nodebpy-520.22.0 → nodebpy-520.24.0}/src/nodebpy/nodes/compositor/distort.py +0 -0
- {nodebpy-520.22.0 → nodebpy-520.24.0}/src/nodebpy/nodes/compositor/filter.py +0 -0
- {nodebpy-520.22.0 → nodebpy-520.24.0}/src/nodebpy/nodes/compositor/group.py +0 -0
- {nodebpy-520.22.0 → nodebpy-520.24.0}/src/nodebpy/nodes/compositor/input.py +0 -0
- {nodebpy-520.22.0 → nodebpy-520.24.0}/src/nodebpy/nodes/compositor/interface.py +0 -0
- {nodebpy-520.22.0 → nodebpy-520.24.0}/src/nodebpy/nodes/compositor/manual.py +0 -0
- {nodebpy-520.22.0 → nodebpy-520.24.0}/src/nodebpy/nodes/compositor/matte.py +0 -0
- {nodebpy-520.22.0 → nodebpy-520.24.0}/src/nodebpy/nodes/compositor/output.py +0 -0
- {nodebpy-520.22.0 → nodebpy-520.24.0}/src/nodebpy/nodes/compositor/vector.py +0 -0
- {nodebpy-520.22.0 → nodebpy-520.24.0}/src/nodebpy/nodes/geometry/__init__.py +0 -0
- {nodebpy-520.22.0 → nodebpy-520.24.0}/src/nodebpy/nodes/geometry/assets.py +0 -0
- {nodebpy-520.22.0 → nodebpy-520.24.0}/src/nodebpy/nodes/geometry/attribute.py +0 -0
- {nodebpy-520.22.0 → nodebpy-520.24.0}/src/nodebpy/nodes/geometry/color.py +0 -0
- {nodebpy-520.22.0 → nodebpy-520.24.0}/src/nodebpy/nodes/geometry/converter.py +0 -0
- {nodebpy-520.22.0 → nodebpy-520.24.0}/src/nodebpy/nodes/geometry/geometry.py +0 -0
- {nodebpy-520.22.0 → nodebpy-520.24.0}/src/nodebpy/nodes/geometry/grid.py +0 -0
- {nodebpy-520.22.0 → nodebpy-520.24.0}/src/nodebpy/nodes/geometry/group.py +0 -0
- {nodebpy-520.22.0 → nodebpy-520.24.0}/src/nodebpy/nodes/geometry/groups.py +0 -0
- {nodebpy-520.22.0 → nodebpy-520.24.0}/src/nodebpy/nodes/geometry/input.py +0 -0
- {nodebpy-520.22.0 → nodebpy-520.24.0}/src/nodebpy/nodes/geometry/interface.py +0 -0
- {nodebpy-520.22.0 → nodebpy-520.24.0}/src/nodebpy/nodes/geometry/manual.py +0 -0
- {nodebpy-520.22.0 → nodebpy-520.24.0}/src/nodebpy/nodes/geometry/output.py +0 -0
- {nodebpy-520.22.0 → nodebpy-520.24.0}/src/nodebpy/nodes/geometry/texture.py +0 -0
- {nodebpy-520.22.0 → nodebpy-520.24.0}/src/nodebpy/nodes/geometry/utilities.py +0 -0
- {nodebpy-520.22.0 → nodebpy-520.24.0}/src/nodebpy/nodes/geometry/vector.py +0 -0
- {nodebpy-520.22.0 → nodebpy-520.24.0}/src/nodebpy/nodes/geometry/zone.py +0 -0
- {nodebpy-520.22.0 → nodebpy-520.24.0}/src/nodebpy/nodes/shader/__init__.py +0 -0
- {nodebpy-520.22.0 → nodebpy-520.24.0}/src/nodebpy/nodes/shader/assets.py +0 -0
- {nodebpy-520.22.0 → nodebpy-520.24.0}/src/nodebpy/nodes/shader/color.py +0 -0
- {nodebpy-520.22.0 → nodebpy-520.24.0}/src/nodebpy/nodes/shader/converter.py +0 -0
- {nodebpy-520.22.0 → nodebpy-520.24.0}/src/nodebpy/nodes/shader/grid.py +0 -0
- {nodebpy-520.22.0 → nodebpy-520.24.0}/src/nodebpy/nodes/shader/group.py +0 -0
- {nodebpy-520.22.0 → nodebpy-520.24.0}/src/nodebpy/nodes/shader/input.py +0 -0
- {nodebpy-520.22.0 → nodebpy-520.24.0}/src/nodebpy/nodes/shader/manual.py +0 -0
- {nodebpy-520.22.0 → nodebpy-520.24.0}/src/nodebpy/nodes/shader/output.py +0 -0
- {nodebpy-520.22.0 → nodebpy-520.24.0}/src/nodebpy/nodes/shader/script.py +0 -0
- {nodebpy-520.22.0 → nodebpy-520.24.0}/src/nodebpy/nodes/shader/shader.py +0 -0
- {nodebpy-520.22.0 → nodebpy-520.24.0}/src/nodebpy/nodes/shader/texture.py +0 -0
- {nodebpy-520.22.0 → nodebpy-520.24.0}/src/nodebpy/nodes/shader/vector.py +0 -0
- {nodebpy-520.22.0 → nodebpy-520.24.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
|
# ---------------------------------------------------------------------------
|
|
@@ -937,9 +946,20 @@ def _ordering_edges(node_tree, keep_reroutes: bool = False):
|
|
|
937
946
|
"""(from, to) node pairs that must hold in emission order: effective
|
|
938
947
|
links (canonical order, reroutes collapsed) plus a synthetic edge from
|
|
939
948
|
each zone input node to its paired output, so the zone wrapper is
|
|
940
|
-
declared before the output side is emitted.
|
|
949
|
+
declared before the output side is emitted.
|
|
950
|
+
|
|
951
|
+
Links from Group Input nodes impose no order: they render as interface
|
|
952
|
+
references (bound in the interface block, before any node emits), and
|
|
953
|
+
a tree holding several instances (split inputs) must not let the
|
|
954
|
+
instances' names gate their consumers' readiness in the lexicographic
|
|
955
|
+
topological sort — which instance feeds a consumer follows link
|
|
956
|
+
creation order, so emission order would depend on the previous
|
|
957
|
+
emission and oscillate across dump → build round trips."""
|
|
941
958
|
for link in _effective_links(node_tree, keep_reroutes):
|
|
942
|
-
if
|
|
959
|
+
if (
|
|
960
|
+
link.from_node != link.to_node
|
|
961
|
+
and link.from_node.bl_idname != "NodeGroupInput"
|
|
962
|
+
):
|
|
943
963
|
yield link.from_node, link.to_node
|
|
944
964
|
for node in node_tree.nodes:
|
|
945
965
|
paired = getattr(node, "paired_output", None)
|
|
@@ -1203,7 +1223,7 @@ class EmitContext:
|
|
|
1203
1223
|
vector feeding ``vec.x`` / ``vec.y``). The assignment is queued on
|
|
1204
1224
|
``pending_lines`` and flushed before the consuming statement.
|
|
1205
1225
|
"""
|
|
1206
|
-
label = link.from_socket.name or link.from_node
|
|
1226
|
+
label = link.from_socket.name or _node_var_label(link.from_node)
|
|
1207
1227
|
var = _make_var(label, self.counter)
|
|
1208
1228
|
self.pending_lines.append(f" {var} = {expr.render()}")
|
|
1209
1229
|
ref = Ref(var)
|
|
@@ -4491,7 +4511,7 @@ def _emit_tree(node_tree, collector: _GroupCollector) -> _TreeEmission:
|
|
|
4491
4511
|
f"Cannot generate code: {message}. Register an emitter "
|
|
4492
4512
|
"with register_emitter() or pass strict=False."
|
|
4493
4513
|
)
|
|
4494
|
-
var = _make_var(node
|
|
4514
|
+
var = _make_var(_node_var_label(node), ctx.counter)
|
|
4495
4515
|
if not ctx.outgoing.get(name):
|
|
4496
4516
|
var = "_" + var
|
|
4497
4517
|
ctx.var_map[name] = _Val(Ref(var))
|
|
@@ -4577,7 +4597,7 @@ def _emit_tree(node_tree, collector: _GroupCollector) -> _TreeEmission:
|
|
|
4577
4597
|
consumed_out_links.add(id(link))
|
|
4578
4598
|
continue
|
|
4579
4599
|
|
|
4580
|
-
var = _make_var(node
|
|
4600
|
+
var = _make_var(_node_var_label(node), ctx.counter)
|
|
4581
4601
|
# A node created purely for its side effect (a gizmo, a dangling
|
|
4582
4602
|
# node) is never referenced again — prefix its variable so the
|
|
4583
4603
|
# 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
|