Draw Pie Chart in Android?

前端 未结 5 1412
耶瑟儿~
耶瑟儿~ 2020-12-14 12:09

I need to draw Pie Chart (Dynamic Values).How to create the Chart without using 3rd party API.

5条回答
  •  感动是毒
    2020-12-14 12:52

    The answer by Ramesh works almost fine. However the white glitch at the end is caused by rounding errors from casting float to int. Simply change the type of "temp" to float, and remove the cast to (int) at the end when "temp += value_degree[i-1]" and it's perfect.

提交回复
热议问题