DEV Community

Discussion on: Jetpack Compose Desktop rendering performances

 
gz_k profile image
Gaetan Zoritchak

Sorry for the mistake; I read your message too fast.

I tried your suggestion with one path and moving the canvas before drawing it. It’s still a little bit under the first implementation performances but more stable (no more freezing).

RenderingWith.Diamond -> {
    canvas.translate(x,y)
    drawPath(diamond, color)
    canvas.translate(-x,-y)
}
Enter fullscreen mode Exit fullscreen mode