Add new node asset scripts for geometry and shader operations

- Implemented `build_mesh_plane.py` to create a geometry node group for mesh planes with customizable parameters.
- Created `build_shadeless.py` for a shader node group that displays color without scene lighting while preserving shadows and reflections.
- Added `validate.py` to validate the integrity of the newly created node groups and their inputs.
- Introduced `validate_cutout.py` to ensure the functionality of cutout node groups and their dependencies.
- Developed `validate_mesh_plane.py` to test the mesh plane creation and its modifier settings.
This commit is contained in:
2026-08-30 00:17:29 +08:00
parent 7d39fe8c5e
commit 32bcd45d7b
168 changed files with 7213 additions and 13121 deletions

27
docs/guides/mesh-plane.md Normal file
View File

@@ -0,0 +1,27 @@
# Plane
Plane 把 Image Empty 转换为带图片材质的普通网格,不运行 AI,也不生成深度估算。它适合广告牌、图片卡片、背景板,以及视频或序列贴图。
## 创建
1. 在 3D View 中选中 Image Empty。
2. 右键选择 **AnyImage > Convert to Plane**。
3. 在 Last Operation 中按需调整 **Subdivide**。
转换会立即创建结果并替换源 Empty。新对象继承原对象的 Transform、图片显示比例和 Offset;需要保留源 Empty 时,请先复制对象。
## Geometry Nodes
结果使用 `O Mesh Plane` 修改器:
- **Subdivide** 使用二分级别控制网格密度,`3` 表示短边约 `8` 段;
- **Thickness** 沿平面法线增加厚度,`0` 输出真正的单面;
- **Material** 由 AnyImage 自动连接。
原始 Mesh 数据只有一个四边形,细分和厚度都由修改器实时生成,可以在转换后继续调整。
## 剪贴板 Plane
在 3D View 中粘贴剪贴板图片,并在 Last Operation 把 **Import As** 改为 **Plane**,也会创建同样的基础网格和 `O Mesh Plane` 修改器。该入口还可选择 **Shadeless**;Image Empty 的 Convert to Plane 入口不提供 Shadeless 选项。
模块与节点分工见 [Convert to Plane 实现原理](../internals/operators/convert-to-plane.md)。