ComfyUI Node
Mpi Image Resize
Resizes the image to width x height. keep_proportion keeps the aspect ratio by the highest dimension (resize), pads the rest (pad*), crops to fill (crop) or targets a pixel count.
Mpi Image Resize
- image
- mask
- IMAGE
- width
- height
- mask
◄width512►
◄height512►
◄upscale_method▾►
◄keep_proportionstretch►
◄pad_color0, 0, 0►
◄crop_positioncenter►
◄divisible_by2►
◄device▾►
CategoryMpiNodes/KJ
Inputs (10)
| Name | Type | Default | Description |
|---|---|---|---|
| image | IMAGE | — | |
| width | INT | 5120–16384 | — |
| height | INT | 5120–16384 | — |
| upscale_method | COMBO | 5 options: nearest-exact, bilinear, area, bicubic, lanczos | |
| keep_proportion | COMBO | stretch | 8 options: stretch, resize, pad, pad_edge, pad_edge_pixel, crop, +2 |
| pad_color | STRING | 0, 0, 0 | Color to use for padding. |
| crop_position | COMBO | center | 5 options: center, top, bottom, left, right |
| divisible_by | INT | 20–512 | — |
| maskopt | MASK | — | |
| deviceopt | COMBO | 2 options: cpu, gpu |
Outputs (4)
| Name | Type | Description |
|---|---|---|
| IMAGE | IMAGE | — |
| width | INT | — |
| height | INT | — |
| mask | MASK | — |