Add new functionality for image rectification and depth metadata handling

- Implemented a preview tool for rectifying images with interactive aspect controls in `preview.py`.
- Added tests for depth metadata loading to ensure consistent schema usage in `test_depth_metadata.py`.
- Developed comprehensive tests for cutout calibration processes in `test_cutout_calibration.py`, including stability checks and depth calibration.
- Created tests for frame compositing operations in `test_frame_compositing.py`, ensuring correct handling of depth and transparency.
- Introduced material slot inheritance functionality in `material_slots.py` to manage geometry material assignments.
- Built shared shader nodes for material processing in `shader.py`, including roughness and bump mapping setups.
This commit is contained in:
2026-09-12 19:20:06 +08:00
parent e8268504c2
commit 938d95db0f
175 changed files with 3812 additions and 6864 deletions

View File

@@ -2,8 +2,8 @@ from unittest.mock import patch
import numpy as np
from anyimage.operators.cutout_tool import geometry as cutout_geometry
from anyimage.operators.cutout_tool.geometry import poisson_balloon_profile
from anyimage.operators.cutout_tool import balloon
from anyimage.operators.cutout_tool.balloon import poisson_balloon_profile
def test_poisson_balloon_profile_is_zero_on_boundary_and_positive_inside():
@@ -62,11 +62,11 @@ def test_teddy_balloon_profile_uses_chordal_axis_radius():
nodes = np.asarray(((1, 1), (3, 1)), dtype=float)
with patch.object(
cutout_geometry,
balloon,
"chordal_axis",
return_value=(nodes, [(0, 1)], np.asarray((1.0, 1.0))),
):
profile = cutout_geometry.teddy_balloon_heights(
profile = balloon.teddy_balloon_heights(
points,
faces,
points[:4],