<!--
{
  "availability" : [
    "iOS: 18.0.0 -",
    "iPadOS: 18.0.0 -",
    "macOS: 15.0.0 -",
    "tvOS: 18.0.0 -",
    "visionOS: 2.0.0 -",
    "watchOS: 27.0.0 -"
  ],
  "documentType" : "symbol",
  "framework" : "Vision",
  "identifier" : "/documentation/Vision/NormalizedRect",
  "metadataVersion" : "0.1.0",
  "role" : "Structure",
  "symbol" : {
    "kind" : "Structure",
    "modules" : [
      "Vision"
    ],
    "preciseIdentifier" : "s:6Vision14NormalizedRectV"
  },
  "title" : "NormalizedRect"
}
-->

# NormalizedRect

The location and dimensions of a rectangle.

```
struct NormalizedRect
```

## Topics

### Creating a normalized rectangle

[`init(x:y:width:height:)`](/documentation/Vision/NormalizedRect/init(x:y:width:height:))

Creates a rectangle with the specified coordinates.

[`init(imageRect:in:)`](/documentation/Vision/NormalizedRect/init(imageRect:in:))

Creates a normalized rectangle from a rectangle in an image coordinate space.

[`init(imageRect:in:normalizedTo:)`](/documentation/Vision/NormalizedRect/init(imageRect:in:normalizedTo:))

Creates a rectangle normalized to a region of interest in an image from a rectangle in an image coordinate space.

[`init(normalizedRect:)`](/documentation/Vision/NormalizedRect/init(normalizedRect:))

Creates a rectangle from the specified Core Graphics rectangle.

[`fullImage`](/documentation/Vision/NormalizedRect/fullImage)

A normalized rectangle with an origin at zero and a width and height of one.

### Inspecting a normalized rectangle

[`cgRect`](/documentation/Vision/NormalizedRect/cgRect)

The normalized rectangle as a Core Graphics rectangle.

[`origin`](/documentation/Vision/NormalizedRect/origin)

The lower left-hand corner of the rectangle.

[`width`](/documentation/Vision/NormalizedRect/width)

The width of the rectangle.

[`height`](/documentation/Vision/NormalizedRect/height)

The height of the rectangle.

### Converting rectangles

[`toImageCoordinates(_:origin:)`](/documentation/Vision/NormalizedRect/toImageCoordinates(_:origin:))

Converts a rectangle in normalized coordinates into image coordinates.

[`toImageCoordinates(from:imageSize:origin:)`](/documentation/Vision/NormalizedRect/toImageCoordinates(from:imageSize:origin:))

Converts a rectangle normalized to a region within an image into full image coordinates.

### Flipping a normalized rectangle

[`verticallyFlipped()`](/documentation/Vision/NormalizedRect/verticallyFlipped())

Returns a normalized rectangle with the origin flipped between the top and bottom of the image.

## Relationships

### Conforms To

[`SendableMetatype`](/documentation/Swift/SendableMetatype)

[`Equatable`](/documentation/Swift/Equatable)

[`Sendable`](/documentation/Swift/Sendable)

[`Decodable`](/documentation/Swift/Decodable)

[`Encodable`](/documentation/Swift/Encodable)

[`Hashable`](/documentation/Swift/Hashable)

[`CustomStringConvertible`](/documentation/Swift/CustomStringConvertible)

---

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)