made this in Compose using some clever geometry bu...
# compose
s
made this in Compose using some clever geometry but wondering is there’s an easier way to draw 3d things natively in compose. for eg: How do i draw a cuboid with rounded edges using Compose?
😯 3
r
The latest version of Android has a feature for this (to draw arbitrary meshes) but you'd be trading one difficulty for another 🤷‍♂️
🙌 1
s
thx @romainguy i’ll look into it!
r
I wouldn't bother, it's only for the latest API level and you'll now have to worry about tessellating curves into meshes.
👍 1
t
In theory if you want to do just small effects you could use AGSL. It is very limited what you can do. But i was able to create this 3d things.
r
SDFs are pretty inefficient and you’ll have the same problem of being limited to certain API levels (better than the latest though)
t
Yes that is correct that they are inefficient. But you can also use them in Compose Multiplatform. And it works almost everywhere. But yes you are very limited what you can do.
c
these look so sick 😎
🙌 1