I’m trying to achieve something pretty simple in theory: overlaying a logo onto a specific part of a base image. To do this properly, I want to use:
Base image – the photo with for example tshirt.
Logo image – a PNG with the actual logo.
Mask – image with alpha layer equal to 0 in specific area (that should be edited) with height and width the same as base image
Now, here’s the problem:
on image/edit
gpt-image-1 accepts more than one image, but the mask is soft and it regenerates the whole image instead of given area.
DALL·E 2 inpainting API allows only one uploaded image at a time, so I can’t pass all three inputs (but mask works well).
Maybe DALL·E 3 accept more than 1 image? image.edit only works with DALL·E 2, and not DALL·E 3. Will it be available in the future on image/edit?
Is there a way to solve this within the current API limits?
Or is this kind of multi-image input (base + overlay + mask) something that might be supported in the future for DALLE?
Yeah, I’ve run into the same limitation. Right now, there’s no way to use all three (base image + logo + mask) directly through the API. Best workaround is to compose the image yourself with something like Python (Pillow/OpenCV), then send it to the API if needed. Would be great if future updates allowed multi-image input!
Multi-image input is available on the edits endpoint now with gpt-image-1.
What the gpt-image-1 model is NOT is a model that can actually edit an image, follow a mask channel image or obey it at all, or even outfill reliably without zooming and cropping instead of outfill. It will and can only re-create the image, using poor-quality vision.
That does allow you to prompt the AI. The waste is that the edits endpoint doesn’t allow you to properly interleave images with messages, so you have to refer by image content in your prompt to exactly which is the base image to replicate, and which is the amendment or alteration.
So you don’t need to do more than send the two images as individual parts in the edits API request; you don’t need a mask. Then meticulously describe what you want done with them.