<!--
{
  "documentType" : "article",
  "framework" : "Accelerate",
  "identifier" : "/documentation/Accelerate/1578976-processing-flags",
  "metadataVersion" : "0.1.0",
  "role" : "collectionGroup",
  "title" : "Processing Flags"
}
-->

# Processing Flags

Set flags on vImage operations to specify processing options.

## Discussion

You can pass multiple flags to a function by adding the flag values together. For example, to leave alpha unchanged and turn off tiling, you can pass:

```objc
kvImageLeaveAlphaUnchanged + kvImageDoNotTile
```

Three of the flags are mutually exclusive: `kvImageCopyInPlace`, `kvImageBackgroundColorFill`, and `kvImageEdgeExtend`. Never pass more than one of these flag values in the same flag parameter.

When passing flags to a function, do not set values for flags that are not used by the function. If the function requires you to set certain flag values, do so. For example, for the convolution function, you must set exactly one of `kvImageCopyInPlace`, `kvImageBackgroundColorFill`, and `kvImageEdgeExtend`.  Otherwise the function may return an error. If you don’t want to set flag values, pass `kvImageNoFlags`.

## Topics

### Constants

[`struct Options`](/documentation/Accelerate/vImage/Options)

Set flags on vImage operations to specify processing options.

[`var kvImageNoFlags: Int`](/documentation/Accelerate/kvImageNoFlags)

A flag that sets the behavior to the default.

[`var kvImageLeaveAlphaUnchanged: Int`](/documentation/Accelerate/kvImageLeaveAlphaUnchanged)

A flag that restricts the operation to red, green, and blue channels only.

[`var kvImageDoNotTile: Int`](/documentation/Accelerate/kvImageDoNotTile)

A flag that disables vImage internal tiling routines.

[`var kvImageHighQualityResampling: Int`](/documentation/Accelerate/kvImageHighQualityResampling)

A flag that uses a higher-quality, slower resampling filter for geometry operations.

[`var kvImageGetTempBufferSize: Int`](/documentation/Accelerate/kvImageGetTempBufferSize)

A flag that returns the minimum temporary buffer size for the operation, given the parameters provided.

[`var kvImagePrintDiagnosticsToConsole: Int`](/documentation/Accelerate/kvImagePrintDiagnosticsToConsole)

A flag that prints a debug message if the operation fails.

[`var kvImageNoAllocate: Int`](/documentation/Accelerate/kvImageNoAllocate)

A flag that prevents vImage from allocating additional storage.

[`var kvImageHDRContent: Int`](/documentation/Accelerate/kvImageHDRContent)

A flag that uses HDR-aware methods.

[`var kvImageDoNotClamp: Int`](/documentation/Accelerate/kvImageDoNotClamp)

A flag that disables clamping in some conversions to floating-point formats.

[`var kvImageUseFP16Accumulator: Int`](/documentation/Accelerate/kvImageUseFP16Accumulator)

A flag that specifies vImage uses faster but lower-precision internal arithmetic for floating-point 16-bit operations.

### Edging Modes

[`var kvImageCopyInPlace: Int`](/documentation/Accelerate/kvImageCopyInPlace)

A flag that copies the value of the edge pixel in the source to the destination.

[`var kvImageBackgroundColorFill: Int`](/documentation/Accelerate/kvImageBackgroundColorFill)

A flag that uses the background color for missing pixels.

[`var kvImageEdgeExtend: Int`](/documentation/Accelerate/kvImageEdgeExtend)

A flag that extends the edges of the image infinitely.

[`var kvImageTruncateKernel: Int`](/documentation/Accelerate/kvImageTruncateKernel)

A flag that uses only the part of the kernel that overlaps the image.



---

Copyright &copy; 2026 Apple Inc. All rights reserved. | [Terms of Use](https://www.apple.com/legal/internet-services/terms/site.html) | [Privacy Policy](https://www.apple.com/privacy/privacy-policy)