---
title: "rotateRad"
description: "Add a rotation (in radians clockwise) to the current transform at the given pivot point. The
pivot coordinate remains unchanged by the rotation transformation"
type: "function"
---

<div class='type'>Function</div>


<a id='references'></a>
<div class='sourceset sourceset-common'>Common</div>


```kotlin
fun Canvas.rotateRad(radians: Float, pivotX: Float = 0.0f, pivotY: Float = 0.0f)
```


Add a rotation (in radians clockwise) to the current transform at the given pivot point. The
pivot coordinate remains unchanged by the rotation transformation

#### Parameters

| | |
| --- | --- |
| radians | Rotation transform to apply to the `Canvas` |
| pivotX | The x-coord for the pivot point |
| pivotY | The y-coord for the pivot point |




<div class='sourceset sourceset-common'>Common</div>


```kotlin
inline fun DrawTransform.rotateRad(radians: Float, pivot: Offset = center) =
    rotate(degrees(radians), pivot)
```


Add a rotation (in radians clockwise) to the current transform at the given pivot point. The
pivot coordinate remains unchanged by the rotation transformation

#### Parameters

| | |
| --- | --- |
| radians | to rotate clockwise |
| pivot | The coordinate for the pivot point, defaults to the center of the coordinate space |




<div class='sourceset sourceset-common'>Common</div>


```kotlin
inline fun DrawScope.rotateRad(
    radians: Float,
    pivot: Offset = center,
    block: DrawScope.() -> Unit,
)
```


Add a rotation (in radians clockwise) to the current transform at the given pivot point. The
pivot coordinate remains unchanged by the rotation transformation

#### Parameters

| | |
| --- | --- |
| radians | to rotate clockwise |
| pivot | The coordinate for the pivot point, defaults to the center of the coordinate space |
| block | lambda that is called to issue drawing commands within the rotated coordinate space |




