---
title: RotateGesture3D
framework: swiftui
role: symbol
role_heading: Structure
path: swiftui/rotategesture3d
---

# RotateGesture3D

A gesture that recognizes 3D rotation motion and tracks the angle and axis of the rotation.

## Declaration

```swift
nonisolated struct RotateGesture3D
```

## Overview

Overview You can constrain this gesture to recognize rotation about a specific 3D axis. For example, RotateGesture3D(constrainedToAxis: .x) creates a gesture that recognizes rotation only around the global X axis. The axis you provide will be normalized. A rotation gesture tracks how a rotation event sequence changes. To recognize a rotation gesture on a view, create and configure the gesture, and then add it to the view using the gesture(_:including:) modifier.

## Topics

### Creating the gesture

- [init(constrainedToAxis:minimumAngleDelta:)](swiftui/rotategesture3d/init(constrainedtoaxis:minimumangledelta:).md)
- [init(constrainedToAxis:minimumAngleDelta:inputKinds:)](swiftui/rotategesture3d/init(constrainedtoaxis:minimumangledelta:inputkinds:).md)
- [minimumAngleDelta](swiftui/rotategesture3d/minimumangledelta.md)
- [constrainedAxis](swiftui/rotategesture3d/constrainedaxis.md)

## Relationships

### Conforms To

- [Gesture](swiftui/gesture.md)

## See Also

### Recognizing gestures that change over time

- [gesture(_:)](swiftui/view/gesture(_:).md)
- [gesture(_:isEnabled:)](swiftui/view/gesture(_:isenabled:).md)
- [gesture(_:name:isEnabled:)](swiftui/view/gesture(_:name:isenabled:).md)
- [gesture(_:including:)](swiftui/view/gesture(_:including:).md)
- [DragGesture](swiftui/draggesture.md)
- [WindowDragGesture](swiftui/windowdraggesture.md)
- [MagnifyGesture](swiftui/magnifygesture.md)
- [RotateGesture](swiftui/rotategesture.md)
- [GestureMask](swiftui/gesturemask.md)
