TTP Smart Tile Interactive Crop
The entry point of Smart Tile 2.0
- source_image
- vision_model
- vision_conditioning
- clip
- qwen_vl_model
- source_image
- tiles
- tile_set
- tile_meta
- positions
- preview
- layout_json
This is where you start every Smart Tile 2.0 workflow, and it's the single most thoroughly documented node in the entire pack's README - for good reason, since it's an interactive editor with its own on-canvas UI, not just a data-in-data-out node. If TTP Tile 1.0 (TTP_Image_Tile_Batch + TTP_Image_Assy) is "cut into an even grid," Smart Tile is "let a human, or SAM/QwenVL, decide where the interesting regions actually are" - so a face tile can be small and detailed while the background stays as one large tile.
What it is and why it exists. A plain grid cuts a face or a hand right down the middle exactly as often as it doesn't, which wrecks detail in exactly the regions you cared most about. Smart Tile's fix is variable-size, object-aware tiles: draw them by hand, paint a mask and convert it to a tile, or point an auto-detector (SAM3.1 or a locally-loaded QwenVL3 model) at the image and let it find faces, hands, text, and other "important object" regions for you.
How it works. You either load an image directly (like ComfyUI's native Load Image) or connect a source_image. The current tile layout lives in a layout_json widget - a hidden text field that persists your plan so the workflow remembers it across runs, not just the current session. auto_detect_mode controls whether anything runs automatically: none leaves you fully manual, sam3.1 needs an official SAM3/SAM3.1 model wired into vision_model plus clip or vision_conditioning, and qwenvl3 needs a qwen_vl_model from the companion TTP QwenVL3 Local Loader node (this node can't read a QwenVL .safetensors file directly - you load it separately and pass the model object in). auto_prompt (default: "person, face, hands, eyes, text, foreground object, important object") is what the auto-detector looks for.
A few of the editor's on-canvas actions worth knowing about, since they're not obvious from the node's ports:
- Auto Tile runs SAM3.1 or QwenVL3 detection and writes the result into the layout.
- Mask to Tile turns a painted region into an object tile; Merge tiles/masks lets you multi-select and combine.
- Fill gaps adds background tiles for anything the auto-detector missed, and Refresh masks re-crops inherited masks after you manually nudge a sub-tile.
Inputs that matter beyond the auto-detect trio above: default_pad (128) and default_blend (64) set the seam overlap and paste-blend width new tiles get; auto_max_tiles (16) caps how many tiles Auto Tile plus gap-filling can produce in total - worth raising if you're working on a genuinely busy image and the detector is running out of tile budget before it covers everything.
Outputs: tiles (the cropped tile images), tile_set and tile_meta (the structured data every downstream Smart Tile node reads), positions, a preview image, and layout_json if you want to save or reuse the exact plan elsewhere. This node is also flagged as an output node - it has its own live UI panel, not just graph connections.
Install. ComfyUI Manager, search "Comfyui_TTP_Toolset", or cd ComfyUI/custom_nodes && git clone https://github.com/TTPlanetPig/Comfyui_TTP_Toolset, restart. If you want sam3.1 auto-detect, you need ComfyUI's official SAM3/SAM3.1 model set up separately; for qwenvl3, you need a QwenVL3 checkpoint downloaded into ComfyUI/models/text_encoders and loaded via TTP QwenVL3 Local Loader.
Common issues, straight from the README's own troubleshooting table: if Auto Tile "does nothing," check that auto_detect_mode is actually set to sam3.1 or qwenvl3 (not left at none) and that the required model input is actually connected - then read the editor's own status message, which tells you why it didn't run. If you manually moved a masked tile and it's still showing the old mask shape, click Refresh masks. And if you only wanted one automatic detection pass and don't want re-running the workflow to silently redo it and wipe your manual edits, set auto_detect_mode back to none once you're happy with the layout.
Inputs (19)
| Name | Type | Default | Description |
|---|---|---|---|
| image | COMBO | 1 options: example.png | |
| layout_json | STRING | {"tiles":[{"name":"tile_1","x0":0.0,"y0":0.0,"x1":0.5,"y1":0.5},{"name":"tile_2","x0":0.5,"y0":0.0,"x1":1.0,"y1":0.5},{"name":"tile_3","x0":0.0,"y0":0.5,"x1":0.5,"y1":1.0},{"name":"tile_4","x0":0.5,"y0":0.5,"x1":1.0,"y1":1.0}]} | — |
| default_pad | INT | 1280–2048 | — |
| default_blend | INT | 640–1024 | — |
| include_full_image | BOOLEAN | false | — |
| round_to | INT | 81–128 | — |
| auto_detect_mode | COMBO | none | 3 options: none, sam3.1, qwenvl3 |
| auto_detect_request | INT | 00–2147483647 | — |
| auto_prompt | STRING | person, face, hands, eyes, text, foreground object, important object | — |
| allow_object_overlap | BOOLEAN | true | — |
| auto_object_padding | INT | 960–2048 | — |
| auto_mask_expand | INT | 160–2048 | — |
| auto_max_tiles | INT | 161–64 | — |
| auto_paint_mask | STRING | — | |
| source_imageopt | IMAGE | — | |
| vision_modelopt | MODEL | — | |
| vision_conditioningopt | CONDITIONING | — | |
| clipopt | CLIP | — | |
| qwen_vl_modelopt | TTP_QWENVL3_MODEL | — |
Outputs (7)
| Name | Type | Description |
|---|---|---|
| source_image | IMAGE | — |
| tiles | IMAGE | — |
| tile_set | TTP_SMART_TILE_SET | — |
| tile_meta | TTP_SMART_TILE_META | — |
| positions | LIST | — |
| preview | IMAGE | — |
| layout_json | STRING | — |