<!--
{
  "availability" : [
    "iOS: 15.0.0 -",
    "iPadOS: 15.0.0 -",
    "macCatalyst: 15.0.0 -",
    "macOS: 12.0.0 -",
    "tvOS: 26.0.0 -",
    "visionOS: -"
  ],
  "documentType" : "symbol",
  "framework" : "RealityKit",
  "identifier" : "/documentation/RealityKit/OrbitAnimation/axis",
  "metadataVersion" : "0.1.0",
  "role" : "Instance Property",
  "symbol" : {
    "kind" : "Instance Property",
    "modules" : [
      "RealityKit"
    ],
    "preciseIdentifier" : "s:17RealityFoundation14OrbitAnimationV4axiss5SIMD3VySfGvp"
  },
  "title" : "axis"
}
-->

# axis

A 3D vector that points in the direction of the axis around which to
rotate.

```
var axis: SIMD3<Float> { get set }
```

## Discussion

You can rotate an object around any axis. For example, if you set a `1`
in the vector’s x-coordinate, rotation occurs around the x-axis, as in
the following code.

```swift
orbitAnimation.axis = SIMD3<Float>(x: 1.0, y: 0.0, z: 0.0)
```

---

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)