Joel Denke
08/02/2024, 4:53 PMcanvas.drawOutline(outline = shadowOutline, paint = Paint().also { paint ->
paint.asFrameworkPaint().apply {
this.color = Color.Transparent.toArgb()
setShadowLayer(
blurRadius.toPx(),
offset.x.toPx() - spreadRadiusPx,
offset.y.toPx() - spreadRadiusPx,
color.toArgb(),
)
}
})
However it looks like if I use a list of items all shadows inside AnimatedContent. When animation enter items it does that before shadow rendering. Looks like it flickering. Is there anything I need tweak. Like merge all layers.
My minimum Android version is 10, so I should be quite free use more latest canvas and shadow stuff?