Bezier Path with dynamic change of width

2020-06-16 05:23发布

问题:


I want to create bezier path with dynamically changing line's width. I need spending the same amount of color on each part of line. So, longer line should be thinner. And shorter line should be bold. Or, at least, line should change it's width from beginning to the end.
Any ideas how to achieve it?
Thank you.

回答1:

the only way to achieve this is with multiple UIBezierPaths of different thickness and colour.