Reputation: 11
I am able to display Pie chart by using A chart engine but I want some animations for that pie chart.
How can I do this?
Upvotes: 1
Views: 1808
Reputation: 32391
For the rotation animation, just call create a Thread
with a loop inside that would include:
renderer.setStartAngle(value);
chartView.repaint();
You will increase the value on every iteration in the loop.
Upvotes: 2
Reputation: 1857
For rotation you can do this using Android xml animation framework over the chart view, using .. more about this here: http://developer.android.com/guide/topics/resources/animation-resource.html
But to show the chart slice by slice it will be harder, you will need to change your Chart Engine.... 2 ways. Make it return every slice in separeted view / drawable and animate it using Android xml... or you can animate direct on canvas. But I am not really sure exactly how, it may be kind hard depending on your chat engine.
Upvotes: 0