Add comprehensive tests for cutout and mesh functionalities

- Introduced `test_cutout.py` to validate cutout pie menu behavior, image lasso options, and mesh detail calculations.
- Added `test_mesh.py` to ensure correct tangent normal rasterization, plane source topology, and depth surface evaluations.
- Created `test_mesh_blender.py` to verify material node groups, tangent baking, and local cutout building from Blender images.
- Implemented tests for handling alpha regions and ensuring geometry nodes maintain expected behavior.
This commit is contained in:
2026-08-26 10:42:29 +08:00
parent 0cf04a13c6
commit 2b79a342b0
46 changed files with 5554 additions and 645 deletions

View File

@@ -1,17 +1,12 @@
from .background import ProcessImageBackground, RemoveImageBackground
from .balloon import (
ActivateBalloonTool,
ExtractBalloon,
AnalyzeBalloon,
)
from .cutout import ActivateCutoutTool, SelectCutoutRegion
from .debug import DebugBen2, DebugDa3, DebugMoge2, DebugUpscale
from .image_edit import CLASSES as IMAGE_EDIT_CLASSES
from .depth_plane import (
from .mesh import (
ConvertCutoutShape,
ConvertToDepthPlane,
ExtractOriginalFrames,
GenerateDa3Depth,
GenerateMoge2Depth,
GenerateOriginalBackground,
ConvertToPlane,
GenerateMesh,
)
from .models import (
ClearModels,
@@ -20,8 +15,6 @@ from .models import (
OpenAIEnvironmentSettings,
SetupAIEnvironment,
)
from .mesh_plane import ConvertToMeshPlane
from .surface import ConvertToSurface, GenerateDa3Surface, GenerateMoge2Surface
from .upscale import UpscaleImage
@@ -34,21 +27,15 @@ CLASSES = (
DebugMoge2,
DebugBen2,
DebugUpscale,
GenerateDa3Depth,
GenerateMoge2Depth,
GenerateDa3Surface,
GenerateMoge2Surface,
GenerateMesh,
SelectCutoutRegion,
ConvertCutoutShape,
ActivateCutoutTool,
ProcessImageBackground,
GenerateOriginalBackground,
ExtractOriginalFrames,
ClearModels,
*IMAGE_EDIT_CLASSES,
ExtractBalloon,
AnalyzeBalloon,
ActivateBalloonTool,
RemoveImageBackground,
UpscaleImage,
ConvertToMeshPlane,
ConvertToPlane,
ConvertToDepthPlane,
ConvertToSurface,
)