<!--
{
  "availability" : [
    "iOS: -",
    "iPadOS: -",
    "macCatalyst: -",
    "macOS: -",
    "tvOS: -",
    "visionOS: -"
  ],
  "documentType" : "symbol",
  "framework" : "CoreImage",
  "identifier" : "/documentation/CoreImage/CIDistanceGradientFromRedMask",
  "metadataVersion" : "0.1.0",
  "role" : "Protocol",
  "symbol" : {
    "kind" : "Protocol",
    "modules" : [
      "Core Image"
    ],
    "preciseIdentifier" : "c:objc(pl)CIDistanceGradientFromRedMask"
  },
  "title" : "CIDistanceGradientFromRedMask"
}
-->

# CIDistanceGradientFromRedMask

The protocol for the Distance Gradient From Red Mask filter.

```
protocol CIDistanceGradientFromRedMask : CIFilterProtocol
```

## Overview

Produces an infinite image where the red channel contains the distance in pixels from each pixel to the mask.

---

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)