Do we have anything like MeshGradient in compose ?...
# compose
s
Do we have anything like MeshGradient in compose ? SwiftUI recently shipped this, also can check out https://x.com/dankuntz/status/1800290461351035346 for an example.
https://gist.github.com/KlassenKonstantin/d5f6ed1d74b3ddbdca699d66c6b9a3b2 Found Something for Android, but uses matrix which is android only
s
There's API Surprisingly, Android has had this API since day one, starting from API level one. However, it's not as convenient as what SwiftUI offers https://developer.android.com/reference/android/graphics/Canvas#drawVertices(android.graphics.Canvas.VertexMode,%20int,%20float[],%20int,%20float[],%20int,%20int[],%20int,%20short[],%20int,%20int,%20android.graphics.Paint)
As you can see, people have already tried to adapt it for Compose. You can do the same and achieve similar results. https://x.com/sinasamaki/status/1805207996668227771?s=19
👀 1
Oh, I keep forgetting this channel is for Compose Multiplatform, not just Android. 😅