ImageGeneratorExtensions.EditImagesAsync Method     
Definition
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
Edits images based on original images and a text prompt.
public static System.Threading.Tasks.Task<Microsoft.Extensions.AI.ImageGenerationResponse> EditImagesAsync(this Microsoft.Extensions.AI.IImageGenerator generator, System.Collections.Generic.IEnumerable<Microsoft.Extensions.AI.AIContent> originalImages, string prompt, Microsoft.Extensions.AI.ImageGenerationOptions? options = default, System.Threading.CancellationToken cancellationToken = default);
	static member EditImagesAsync : Microsoft.Extensions.AI.IImageGenerator * seq<Microsoft.Extensions.AI.AIContent> * string * Microsoft.Extensions.AI.ImageGenerationOptions * System.Threading.CancellationToken -> System.Threading.Tasks.Task<Microsoft.Extensions.AI.ImageGenerationResponse>
	<Extension()>
Public Function EditImagesAsync (generator As IImageGenerator, originalImages As IEnumerable(Of AIContent), prompt As String, Optional options As ImageGenerationOptions = Nothing, Optional cancellationToken As CancellationToken = Nothing) As Task(Of ImageGenerationResponse)
	Parameters
- generator
 - IImageGenerator
 
The image generator.
- originalImages
 - IEnumerable<AIContent>
 
The images to base edits on.
- prompt
 - String
 
The prompt to guide the image editing.
- options
 - ImageGenerationOptions
 
The image generation options to configure the request.
- cancellationToken
 - CancellationToken
 
The CancellationToken to monitor for cancellation requests. The default is None.
Returns
The images generated by the generator.
Exceptions
generator, originalImages, or prompt is null.