TripoSplat Preprocess Image
This node crops each input image to a centered square on a black background, then adds padding to reach the specified output size. It is designed to prepare images for the TripoSplat 3D model by ensuring consistent square framing and optional alpha matte erosion to prevent border artifacts.Inputs
| Parameter | Description | Data Type | Required | Range |
|---|---|---|---|---|
image | The input image(s) to preprocess | IMAGE | Yes | - |
mask | Alpha mask for the image, used to determine the crop region | MASK | Yes | - |
erode_radius | Erode the alpha matte by this pixel radius before cropping (avoids border bleed). Default: 1 | INT | Yes | 0 to 16 |
size | Square image size. The model is trained at 1024; other sizes run but are off-distribution. Default: 1024 | INT | Yes | 256 to 4096 (step of 16) |
mask input is required and must be provided. If the mask has a different batch size than the image, it is automatically repeated to match. If the mask dimensions differ from the image dimensions, the mask is resized to match the image using bilinear interpolation. The output size is automatically rounded down to the nearest multiple of 16 to ensure compatibility with DINOv3 patch and Flux2 VAE stride requirements.
Outputs
| Output Name | Description | Data Type |
|---|---|---|
image | The preprocessed image(s) cropped to a centered square on a black background with padding | IMAGE |
This documentation was AI-generated. If you find any errors or have suggestions for improvement, please feel free to contribute! Edit on GitHub
Source fingerprint (SHA-256):
3f33dbc3a99ccb23ede767915a28fabdfa388edb8d5782edea3f8d03e5965b2a