pub struct EditImageJsonRequest {Show 15 fields
pub model: Option<ImageModel>,
pub images: Vec<ImageRefParam>,
pub mask: Option<ImageRefParam>,
pub prompt: String,
pub n: Option<u8>,
pub quality: Option<ImageQuality>,
pub input_fidelity: Option<InputFidelity>,
pub size: Option<ImageSize>,
pub user: Option<String>,
pub output_format: Option<ImageOutputFormat>,
pub output_compression: Option<u8>,
pub moderation: Option<ImageModeration>,
pub background: Option<ImageBackground>,
pub stream: Option<bool>,
pub partial_images: Option<u8>,
}Expand description
JSON request body for image edits.
Use images (array of ImageRefParam) instead of multipart image uploads.
You can reference images via external URLs, data URLs, or uploaded file IDs.
JSON edits support GPT image models only; DALL-E edits require multipart (dall-e-2 only).
Fields§
§model: Option<ImageModel>The model to use for image editing.
images: Vec<ImageRefParam>Input image references to edit. For GPT image models, you can provide up to 16 images.
mask: Option<ImageRefParam>An optional mask image reference indicating which areas of the image should be edited.
prompt: StringA text description of the desired image edit.
n: Option<u8>The number of edited images to generate. Must be between 1 and 10.
quality: Option<ImageQuality>The quality of the image that will be generated.
input_fidelity: Option<InputFidelity>Control how much effort the model will exert to match the style and features,
especially facial features, of input images. Supports high and low. Defaults to low.
size: Option<ImageSize>The size of the generated image.
user: Option<String>A unique identifier representing your end-user.
output_format: Option<ImageOutputFormat>The output format for the generated image.
output_compression: Option<u8>The compression level (0-100%) for the generated images.
moderation: Option<ImageModeration>Control the content-moderation level for images.
background: Option<ImageBackground>The background style for the generated image.
stream: Option<bool>Whether to stream the image generation. Defaults to false.
partial_images: Option<u8>The number of partial images to generate during streaming.
Trait Implementations§
Source§impl Clone for EditImageJsonRequest
impl Clone for EditImageJsonRequest
Source§fn clone(&self) -> EditImageJsonRequest
fn clone(&self) -> EditImageJsonRequest
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read more