<!--
{
  "availability" : [
    "iOS: 13.0.0 -",
    "iPadOS: 13.0.0 -",
    "macCatalyst: 13.0.0 -",
    "macOS: 10.15.0 -",
    "tvOS: 26.0.0 -",
    "visionOS: -"
  ],
  "documentType" : "symbol",
  "framework" : "RealityKit",
  "identifier" : "/documentation/RealityKit/BoundingBox/distanceSquared(toPoint:)",
  "metadataVersion" : "0.1.0",
  "role" : "Instance Method",
  "symbol" : {
    "kind" : "Instance Method",
    "modules" : [
      "RealityKit"
    ],
    "preciseIdentifier" : "s:17RealityFoundation11BoundingBoxV15distanceSquared7toPointSfs5SIMD3VySfG_tF"
  },
  "title" : "distanceSquared(toPoint:)"
}
-->

# distanceSquared(toPoint:)

Calculates the distance from a point to the bounding box.

```
func distanceSquared(toPoint: SIMD3<Float>) -> Float
```

## Parameters

`toPoint`

The point.

## Return Value

The square of the distance, in meters, from the point to the
box.

---

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)