Inset & Crop
Chop a border off an image, four edges at a time
- image
- image
Sometimes you don't need a fancy crop - you just need to shave a border off an image. Maybe there's a black bar at the bottom, a watermark strip along an edge, or you shot composition slightly off and want to lose 40 pixels of padding from one side. Inset & Crop is that node: it removes a fixed number of pixels from each of the four edges independently, and it does the same for every image in a batch.
The mechanism, which is basically nothing
It's as simple as it sounds. inset_top, inset_bottom, inset_left, inset_right each take a pixel count, and the node slices that many off the corresponding edge. All four default to 0, which makes the node a pure pass-through - no crop happens until you actually set a value. That's a deliberate design choice worth understanding: it means you can drop the node into a workflow, leave it at defaults, and it does nothing; the moment you type 32 into inset_top, your output loses 32 rows off the top. It accepts an IMAGE input and returns an IMAGE list, so a whole batch gets cropped uniformly, which is the reason it beats doing it in an external editor for video frame sequences or large sets.
The inputs, all of them
image- the input image or batch.inset_top/inset_bottom/inset_left/inset_right- pixels to remove from each edge. Independent, so asymmetric crops are trivial.
That's the whole input surface, and the output is the cropped image batch. No aspect-ratio math, no region selection, no mask. If you need to crop to a specific region rather than shave edges, this isn't the node - you want something like Crop By Mask or a standard bounding-box crop. Inset is specifically the "remove a strip from the edges" tool.
Where it fits
The obvious real-world uses: trimming letterbox bars off video frames before feeding them into a loop or a batch processor, removing a timestamp or watermark band, or cleaning up a generated image that consistently adds a border you don't want. Because it's batch-safe and cheap (pure tensor slicing), it's a natural early stage in an image pipeline rather than a one-off edit. One note: pixel counts are absolute, not relative, so if you're processing images of mixed sizes you'll need to know your smallest dimension before setting a large inset, or you'll slice right through the middle of the smaller frames.
Install
It ships with ComfyUI_Eclipse, so the standard pack install gets it:
cd ComfyUI/custom_nodes
git clone https://github.com/r-vage/ComfyUI_Eclipse
Or install ComfyUI_Eclipse via ComfyUI Manager and restart. No model files, no extra dependencies - this is a couple of tensor slices wrapped in a node. If you just need to lose a border, it's the least-friction option in the pack.
Inputs (5)
| Name | Type | Default | Description |
|---|---|---|---|
| image | IMAGE | Input image or batch. | |
| inset_top | INT | 00–65535 | Pixels to remove from the top edge. |
| inset_bottom | INT | 00–65535 | Pixels to remove from the bottom edge. |
| inset_left | INT | 00–65535 | Pixels to remove from the left edge. |
| inset_right | INT | 00–65535 | Pixels to remove from the right edge. |
Outputs (1)
| Name | Type | Description |
|---|---|---|
| image | IMAGE | — |