Add soft min and max constraints for frame resolution and cutout edge length properties

This commit is contained in:
2026-09-13 11:22:20 +08:00
parent 18799e8828
commit 2a00ed0ee6
21 changed files with 3834 additions and 1293 deletions

View File

@@ -73,12 +73,12 @@ def test_camera_blur_preserves_rays_interior_protection_and_disconnected_surface
def test_cutout_fine_outline_blurs_depth_without_moving_projection():
from tests.support.depth_surface import surface
from anyimage.operators.cutout_tool.fine_mesh import build_fine_mesh
from anyimage.operators.cutout_tool.mesh import build_mesh
obj, set_value = surface(step=0, resolution=8)
yy, xx = np.mgrid[:32, :64]
alpha = ((xx - 32)**2 / 27**2 + (yy - 16)**2 / 13**2 < 1).astype(float)
points, faces, _, _ = build_fine_mesh(alpha, 3, .9)
points, faces, _, _ = build_mesh(alpha, 3, .9)
obj.data.clear_geometry()
obj.data.from_pydata([(x / 32, y / 32, 0) for x, y in points], [], faces.tolist())
uv = obj.data.uv_layers.get("UVMap") or obj.data.uv_layers.new(name="UVMap")