<!--
{
  "documentType" : "article",
  "framework" : "Accelerate",
  "identifier" : "/documentation/Accelerate/histogram",
  "metadataVersion" : "0.1.0",
  "role" : "collectionGroup",
  "title" : "Histogram"
}
-->

# Histogram

Calculate or manipulate an image’s histogram.

## Topics

### Performing contrast stretching

[`vImageContrastStretch_Planar8`](/documentation/Accelerate/vImageContrastStretch_Planar8(_:_:_:))

Performs contrast stretching on an 8-bit planar buffer.

[`vImageContrastStretch_PlanarF`](/documentation/Accelerate/vImageContrastStretch_PlanarF(_:_:_:_:_:_:_:))

Performs contrast stretching on a 32-bit planar buffer.

[`vImageContrastStretch_ARGB8888`](/documentation/Accelerate/vImageContrastStretch_ARGB8888(_:_:_:))

Performs contrast stretching on an 8-bit-per-channel, 4-channel interleaved buffer.

[`vImageContrastStretch_ARGBFFFF`](/documentation/Accelerate/vImageContrastStretch_ARGBFFFF(_:_:_:_:_:_:_:))

Performs contrast stretching on a 32-bit-per-channel, 4-channel interleaved buffer.

### Performing ends-in contrast stretching

[`vImageEndsInContrastStretch_Planar8`](/documentation/Accelerate/vImageEndsInContrastStretch_Planar8(_:_:_:_:_:))

Performs ends-in contrast stretching on an 8-bit planar buffer.

[`vImageEndsInContrastStretch_PlanarF`](/documentation/Accelerate/vImageEndsInContrastStretch_PlanarF(_:_:_:_:_:_:_:_:_:))

Performs ends-in contrast stretching on a 32-bit planar buffer.

[`vImageEndsInContrastStretch_ARGB8888`](/documentation/Accelerate/vImageEndsInContrastStretch_ARGB8888(_:_:_:_:_:))

Performs ends-in contrast stretching on an 8-bit-per-channel, 4-channel interleaved buffer.

[`vImageEndsInContrastStretch_ARGBFFFF`](/documentation/Accelerate/vImageEndsInContrastStretch_ARGBFFFF(_:_:_:_:_:_:_:_:_:))

Performs ends-in contrast stretching on a 32-bit-per-channel, 4-channel interleaved buffer.

### Equalizing a histogram

[`vImageEqualization_Planar8`](/documentation/Accelerate/vImageEqualization_Planar8(_:_:_:))

Performs histogram equalization on an 8-bit planar buffer.

[`vImageEqualization_PlanarF`](/documentation/Accelerate/vImageEqualization_PlanarF(_:_:_:_:_:_:_:))

Performs histogram equalization on a 32-bit planar buffer.

[`vImageEqualization_ARGB8888`](/documentation/Accelerate/vImageEqualization_ARGB8888(_:_:_:))

Performs histogram equalization on an 8-bit-per-channel, 4-channel interleaved buffer.

[`vImageEqualization_ARGBFFFF`](/documentation/Accelerate/vImageEqualization_ARGBFFFF(_:_:_:_:_:_:_:))

Performs histogram equalization on a 32-bit-per-channel, 4-channel interleaved buffer.

### Calculating a histogram

[`vImageHistogramCalculation_Planar8`](/documentation/Accelerate/vImageHistogramCalculation_Planar8(_:_:_:))

Calculates the histogram of an 8-bit planar buffer.

[`vImageHistogramCalculation_PlanarF`](/documentation/Accelerate/vImageHistogramCalculation_PlanarF(_:_:_:_:_:_:))

Calculates the histogram of a 32-bit planar buffer.

[`vImageHistogramCalculation_ARGB8888`](/documentation/Accelerate/vImageHistogramCalculation_ARGB8888(_:_:_:))

Calculates the histogram of an 8-bit-per-channel, 4-channel interleaved buffer.

[`vImageHistogramCalculation_ARGBFFFF`](/documentation/Accelerate/vImageHistogramCalculation_ARGBFFFF(_:_:_:_:_:_:))

Calculates the histogram of a 32-bit-per-channel, 4-channel interleaved buffer.

### Specifying a histogram

[`vImageHistogramSpecification_Planar8`](/documentation/Accelerate/vImageHistogramSpecification_Planar8(_:_:_:_:))

Specifies the histogram of an 8-bit planar buffer.

[`vImageHistogramSpecification_PlanarF`](/documentation/Accelerate/vImageHistogramSpecification_PlanarF(_:_:_:_:_:_:_:_:))

Specifies the histogram of a 32-bit planar buffer.

[`vImageHistogramSpecification_ARGB8888`](/documentation/Accelerate/vImageHistogramSpecification_ARGB8888(_:_:_:_:))

Specifies the histogram of an 8-bit-per-channel, 4-channel interleaved buffer.

[`vImageHistogramSpecification_ARGBFFFF`](/documentation/Accelerate/vImageHistogramSpecification_ARGBFFFF(_:_:_:_:_:_:_:_:))

Specifes the histogram of a 32-bit-per-channel, 4-channel interleaved buffer.



---

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)