Stephen Vinouze
02/03/2022, 5:19 PMrotationMatrix
method where you can specify your anchor point but I don't think it's supported by Compose yet. Am I missing something?romainguy
02/03/2022, 5:49 PMTransformOrigin
that you give to a Modifier.graphicsLayer()
Stephen Vinouze
02/03/2022, 6:19 PMval infiniteTransition = rememberInfiniteTransition()
val angle by infiniteTransition.animateFloat(
initialValue = -10f,
targetValue = 10f,
animationSpec = infiniteRepeatable(
animation = tween(),
repeatMode = RepeatMode.Reverse,
)
)
Modifier.graphicsLayer(
transformOrigin = TransformOrigin(0.5f, 0f),
rotationZ = angle,
)
Thanks @romainguy !