---
title: keystoneCorrectionVertical()
framework: coreimage
role: symbol
role_heading: Type Method
path: coreimage/cifilter-swift.class/keystonecorrectionvertical()
---

# keystoneCorrectionVertical()

Vertically adjusts an image to remove distortion.

## Declaration

```swift
class func keystoneCorrectionVertical() -> any CIFilter & CIKeystoneCorrectionVertical
```

## Return Value

Return Value The adjusted image.

## Discussion

Discussion This method applies the keystone correction vertical. The effect performs vertical adjustment of the image to shape the image to be rectangular. This effect is commonly used with multimedia projectors to correct the distortion caused by the projector being lower or higher than the projected screen. The keystone vertical filter uses the following properties: The following code creates a filter that distorts the image: func keystoneCorrectionVertical(inputImage: CIImage) -> CIImage {     let keystoneCorrect = CIFilter.keystoneCorrectionVertical()     keystoneCorrect.inputImage = inputImage     keystoneCorrect.topLeft = CGPoint(x: 0, y: 3024)     keystoneCorrect.topRight = CGPoint(x: 4032, y: 3024)     keystoneCorrect.bottomLeft = CGPoint(x: 200, y: 0)     keystoneCorrect.bottomRight = CGPoint(x: 4032, y: 0)     keystoneCorrect.focalLength = 18     return keystoneCorrect.outputImage! }

## See Also

### Filters

- [bicubicScaleTransform()](coreimage/cifilter-swift.class/bicubicscaletransform().md)
- [edgePreserveUpsample()](coreimage/cifilter-swift.class/edgepreserveupsample().md)
- [keystoneCorrectionCombined()](coreimage/cifilter-swift.class/keystonecorrectioncombined().md)
- [keystoneCorrectionHorizontal()](coreimage/cifilter-swift.class/keystonecorrectionhorizontal().md)
- [lanczosScaleTransform()](coreimage/cifilter-swift.class/lanczosscaletransform().md)
- [perspectiveCorrection()](coreimage/cifilter-swift.class/perspectivecorrection().md)
- [perspectiveRotate()](coreimage/cifilter-swift.class/perspectiverotate().md)
- [perspectiveTransform()](coreimage/cifilter-swift.class/perspectivetransform().md)
- [perspectiveTransformWithExtent()](coreimage/cifilter-swift.class/perspectivetransformwithextent().md)
- [straighten()](coreimage/cifilter-swift.class/straighten().md)
