🎨 Photopea图像处理 Photopea Processing & Load Image
A real Photoshop-style editor, hanging out inside your ComfyUI graph
- image_input
- image
- mask
The workflow loop that eats everyone's afternoon is: generate, notice the hands are wrong, save the image out, open a real editor, fix it, save again, drag it back into ComfyUI, remember where you put it. This node collapses that loop. Magic Photopea is an image loader with a built-in gallery, and a one-click route to Photopea - the free, browser-based, Photoshop-close editor - with the edited result saved back automatically and re-read by the node.
The README's framing is right: it's a file manager for your ComfyUI/input/ folder plus a seamless edit path. You browse a visual gallery of your uploaded images instead of a dropdown list, send any of them to Photopea, edit in the browser, and the node picks up the saved file on its next run. No download, no upload, no hunting through the input/ directory.
How it works
It's not an API wrapper for some remote image service. Photopea itself is web-based, so the node needs you to be online - the README calls this out explicitly - but the ComfyUI side is just a smart LoadImage: it scans input/, filters to image content types, sorts by modification time (newest first), hides the transient clipspace-* files ComfyUI's own Mask Editor leaves behind, and loads the chosen file.
Two details make it feel alive in a workflow. First, IS_CHANGED returns a fresh value whenever the file on disk changes, so the node re-loads the edited file every run instead of being cache-blind. Second, it handles the official Mask Editor's "save to node" path, which the changelog fixed specifically. The optional image_input socket lets you pipe a tensor in instead of a file, in which case the node re-runs every frame.
Inputs and outputs
image- required, a dropdown of image files in yourinput/folder (with the upload button for new ones)image_input- optional, an IMAGE tensor that overrides the file picker when connected
Outputs are the standard LoadImage pair: image (IMAGE) and mask (MASK), built from the file's alpha channel. Wire them to anything you'd wire a normal loaded image to.
Where people get burned
The README's warnings are worth taking literally. Photopea needs internet - offline it just won't launch. And this node's studio view can physically delete files from your disk. "Delete All" is a real delete, not a soft delete, and the README says to use it with caution. A gallery that deletes is powerful until it isn't; keep a backup of your input/ folder if you're the tidy-up type.
The cache-clearing button exists because the Mask Editor churns out temp files. Use it when the gallery starts looking like a landfill - that's exactly what it's for.
One ComfyUI note: the V1.4.0 update migrated this node to ComfyUI 0.29.0's official image/video parsing pipeline (InputImpl.VideoFromFile, node_helpers, comfy.model_management), plus support for the clipspace-painted-*.png companion files. If it errors on load, check your ComfyUI version first.
Installing
It's part of the Magic-Assistant pack:
cd ComfyUI/custom_nodes/
git clone https://github.com/shigjfg/ComfyUI-Magic-Assistant.git
cd ComfyUI-Magic-Assistant && pip install -r requirements.txt
Restart, then find it under "✨ Magic Assistant". Base dependencies are just openai and aiohttp - nothing heavy - but you do need to be online for the editing half to work.
Inputs (2)
| Name | Type | Default | Description |
|---|---|---|---|
| image | COMBO | 1 options: example.png | |
| image_inputopt | IMAGE | — |
Outputs (2)
| Name | Type | Description |
|---|---|---|
| image | IMAGE | — |
| mask | MASK | — |