---
title: "settingAlphaOne(in:)"
framework: coreimage
role: symbol
role_heading: Instance Method
path: "coreimage/ciimage/settingalphaone(in:)"
---

# settingAlphaOne(in:)

Returns a new image created by setting all alpha values to 1.0 within the specified rectangle and to 0.0 outside of that area.

## Declaration

```swift
func settingAlphaOne(in extent: CGRect) -> CIImage
```

## Parameters

- `extent`: The rectangular area in the image to be set to full opacity.

## Return Value

Return Value An image object representing the result of the operation.

## See Also

### Creating an Image by Modifying an Existing Image

- [applyingFilter(_:parameters:)](coreimage/ciimage/applyingfilter(_:parameters:).md)
- [applyingFilter(_:)](coreimage/ciimage/applyingfilter(_:).md)
- [transformed(by:)](coreimage/ciimage/transformed(by:).md)
- [transformed(by:highQualityDownsample:)](coreimage/ciimage/transformed(by:highqualitydownsample:).md)
- [cropped(to:)](coreimage/ciimage/cropped(to:).md)
- [oriented(forExifOrientation:)](coreimage/ciimage/oriented(forexiforientation:).md)
- [clampedToExtent()](coreimage/ciimage/clampedtoextent().md)
- [clamped(to:)](coreimage/ciimage/clamped(to:).md)
- [composited(over:)](coreimage/ciimage/composited(over:).md)
- [convertingWorkingSpaceToLab()](coreimage/ciimage/convertingworkingspacetolab().md)
- [convertingLabToWorkingSpace()](coreimage/ciimage/convertinglabtoworkingspace().md)
- [matchedToWorkingSpace(from:)](coreimage/ciimage/matchedtoworkingspace(from:).md)
- [matchedFromWorkingSpace(to:)](coreimage/ciimage/matchedfromworkingspace(to:).md)
- [premultiplyingAlpha()](coreimage/ciimage/premultiplyingalpha().md)
- [unpremultiplyingAlpha()](coreimage/ciimage/unpremultiplyingalpha().md)
