---
title: "convert(boundingBox:from:to:)"
framework: realitykit
role: symbol
role_heading: Instance Method
path: "realitykit/realitycoordinatespaceconverting/convert(boundingbox:from:to:)"
---

# convert(boundingBox:from:to:)

Converts a BoundingBox from a RealityKit coordinate space to a Rect3D in a defined SwiftUI coordinate space.

## Declaration

```swift
func convert(boundingBox: BoundingBox, from realitySpace: some RealityCoordinateSpace, to space: some CoordinateSpaceProtocol) -> Rect3D
```
