Class StabilityEraseRequest
Request body for POST /v2beta/stable-image/edit/erase. Removes objects defined by the mask, replacing them with AI-generated background.
Implements
Inherited Members
Namespace: Glitch9.AIDevKit.Stability
Assembly: Glitch9.AIDevKit.Provider.Stability.dll
Syntax
public class StabilityEraseRequest : StabilityRequest, IMultipartFormRequest
Properties
| Edit this page View SourceGrowMask
Optional. Pixels to grow the mask outward. Range: 0 to 20. Default: 5.
Declaration
[JsonProperty("grow_mask")]
public int? GrowMask { get; set; }
Property Value
| Type | Description |
|---|---|
| int? |
Image
Required. Raw bytes of the source image. Formats: jpeg, png, webp. Minimum 64 pixels per side.
Declaration
[JsonProperty("image")]
public byte[] Image { get; set; }
Property Value
| Type | Description |
|---|---|
| byte[] |
Mask
Optional. Grayscale mask defining areas to erase. White pixels are erased; black pixels are preserved. If omitted, the alpha channel is used.
Declaration
[JsonProperty("mask")]
public byte[] Mask { get; set; }
Property Value
| Type | Description |
|---|---|
| byte[] |