ceramic-engine / ceramic

Cross-platform 2D framework written in Haxe that can export natively to desktop (windows, mac, linux), mobile (ios, android), web (js + webgl) and to unity projects
MIT License
254 stars 22 forks source link

[runtime] Add initial implementation of RoundedRect #128

Closed l0go closed 7 months ago

l0go commented 8 months ago

Full credit goes to @fire-h0und who came up with the math and logic, I just made it more ceramic-y.

Few things that might need to be addressed:

  1. Is radius a good name for that parameter? Maybe radii or radiuses? Both felt kinda awkward
  2. Scaling isn't working for me, I assume that setting autoComputeSize to true would work, but didn't know how to get that working.

Thanks!

jeremyfa commented 7 months ago

There is high chance that at some point I change/improve this implementation but until then, let's merge it as is. Thanks! 🙏