How to make a conical gradient in iOS using Core Graphics / Quartz 2D?

后端 未结 4 1091
不思量自难忘°
不思量自难忘° 2020-12-10 05:23

How can I draw such a conical gradient in iOS using Core Graphics / Quartz 2D API?


(source: ods.com.ua)

4条回答
  •  难免孤独
    2020-12-10 06:01

    I wanted pure Swift solution for this, and it was also kind of a challenging task for me.

    At the end, I wrote AEConicalGradient which does that with interesting approach (by using a circle and drawing lines of different colors to the center).

提交回复
热议问题