<!--
{
  "availability" : [
    "iOS: -",
    "iPadOS: -",
    "visionOS: 2.0.0 -"
  ],
  "documentType" : "symbol",
  "framework" : "SwiftUI",
  "identifier" : "/documentation/SwiftUI/WorldScalingCompensation",
  "metadataVersion" : "0.1.0",
  "role" : "Structure",
  "symbol" : {
    "kind" : "Structure",
    "modules" : [
      "SwiftUI"
    ],
    "preciseIdentifier" : "s:7SwiftUI24WorldScalingCompensationV"
  },
  "title" : "WorldScalingCompensation"
}
-->

# WorldScalingCompensation

Indicates whether returned metrics will take dynamic scaling into account.

```
struct WorldScalingCompensation
```

## Overview

On visionOS, a window scene or a volume scene with the [`defaultWorldScaling(_:)`](/documentation/SwiftUI/Scene/defaultWorldScaling(_:))
modifier may scale dynamically when the user repositions it. In those cases,
the metrics returned by a [`PhysicalMetric`](/documentation/SwiftUI/PhysicalMetric) or [`PhysicalMetricsConverter`](/documentation/SwiftUI/PhysicalMetricsConverter)
value may or may not correspond to the units of a `RealityView`.

World scale compensation lets you specify if this scaling is taken into account.
If the values are [`unscaled`](/documentation/SwiftUI/WorldScalingCompensation/unscaled), they will correspond to the physical metrics of the
user’s surroundings, regardless of dynamic scale. If [`scaled`](/documentation/SwiftUI/WorldScalingCompensation/scaled), they will be scaled
appropriately for the scene, which means they will match the default coordinate
system of a `RealityView` in that scene.

## Topics

### Type Properties

[`static let scaled: WorldScalingCompensation`](/documentation/SwiftUI/WorldScalingCompensation/scaled)

Returns metrics that are scaled appropriately to match the coordinate system
of their scene, including any world scaling behavior.

[`static let unscaled: WorldScalingCompensation`](/documentation/SwiftUI/WorldScalingCompensation/unscaled)

Returns metrics that match the scale of the user’s surroundings, regardless
of the world scaling behavior of their scene.

## Relationships

### Conforms To

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

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

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

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

---

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)