2D Animation: Animated Pie Chart Rig

Share this:

One of the different types of animation is called motion graphics, which uses animation technology for conveying messages in multimedia formats. A commonly used motion graphics element is the sweeping circle, such as those you see in data presentations using animated pie charts. The use of an animated pie chart captures the attention of your audience and brings life to your data showcase.

While elements such as the sweeping circle can be achieved very easily with dedicated tools such as Adobe After Effects, users of standard 2D animation tools that support vector animation techniques (like Synfig Studio, Anime Studio, and Toon Boom Studio) can still accomplish some of the effects, albeit with a little more effort and ingenuity.

This post shows you how to create a basic sweeping pie chart animation in Toon Boom Studio using just 3 drawing elements and a Clipping Effect element. The technique also uses only 4 unique keyframes for a full sweep cycle.

Watch the following demo video to see how the rig is built and posed. Several examples of variants of the rig are included at the end of the video (I call these ‘exercises’). The solutions to those exercises are included here in this blog post.

Building & Rigging

As you can see from the video, this technique uses 3 drawn art components, all of which are just rectangles! The Base layer is split into a right half side and a left half side. The left half is filled with the originally visible color (green/lime in the video), while the right half is filled with the ‘revealed’ color.

Sweeping Circle Drawing Layers

The shutters are exact copies of the right half of the base. Shutter1 is colored with the initial color and Shutter2 is filled with the ‘revealed’ color. Building the model in this case is simply drawing, pasting, and coloring the rectangles in the 3 layers.

We then use a Clipping Effect element with a circle mask to create a circle out of the rectangles. The final part of the rigging is to set the Z-offsets for the shutters. Shutter1 has the originally visible color, so should be in front of everything else. Shutter2 has the revealed color and is placed behind Shutter1, but in front of all the other layers. My preferred way of adjusting the Z-positions is by dragging the elements in either the Top View or the Side View (refer to the demo video at 1:53).

Sweeping Circle Drawing Layers

Posing & Animating

Posing and animating the pie chart only involves creating several keyframes, rotating the shutters, and removing Shutter1 after it has served its purpose. We first create the initial keyframes for Shutter1 and Shutter2 in Frame 1. Then at the midpoint (middle frame), we rotate Shutter1 by 180 degrees clockwise to reveal Shutter2. Also at the midpoint, we create a keyframe for Shutter2 (this is the critical keyframe for Shutter2; I realized that the keyframe at Frame 1 is not critical after creating and uploading the video). After the midpoint, we remove Shutter1 from view either by deleting the cells, or sending it to the back (in Z-depth), or using cell swapping in the Cell control tab. Finally, in the final frame of the cycle, we rotate Shutter2 clockwise by 180 degrees.

Watch out for a vertical gap that may show a tiny sliver of the revealed color in Frame 1 (see the demo video at 0:00). If you see this, simply drag the left edge of Shutter1 to the left to close the gap. You can perform the fix using the Transform Tool while in Camera Mode (make sure to temporarily move the rotation pivot point to the other side of the rectangle).

Once you’re done, add a Parent Peg to the rig and save your rig by selecting and dragging the peg element into the Global Library or any of your own custom libraries. Your circle rig is ready for action.

Exercise 1 – Back-to-Back Sweeps

This example reuses the sweeping circle rig three times. Simply drag the rig from your library and drop it into the canvas as shown in the following 2 figures. The first figure shows an overlapping time/frame alignment and is preferred if you really care about fine timing details. The second figure shows a non-overlapping timing arrangement.

Image - TBS Timeline View 0a2

TBS Timeline View

Once you have the elements added, swap the colors of Base Layer, Shutter1, and Shutter2 in the MIDDLE element. Yes, it’s that simple.

Exercise 3 – Radar Sweep

The ‘radar sweep’ is done by changing the initial color (lime/green in the video example) to match the background color.

Exercise 3 – Faster, Slower, Counter-Clockwise Sweeps

Speeding up or slowing down the animation speed only requires grabbing and dragging the peg on its edge with the double-headed arrow showing (see the following figure).

TBS Timeline View

Drag the element to the right to lengthen it in the Timeline to make the animation run slower. Drag and shrink it to get a fast-running animation.

One very important step to remember is to readjust the time when Shutter1 gets out of view. The rotation keyframe must coincide with the new middle frame number, after which Shutter1 needs to get out of the way (turn invisible as described earlier).

Notice that I intentionally flipped the direction of the sweep/rotation for the fast-running little circles in the video. This rig is pretty flexible.

Other Variants

Here are several suggestions for more experiments you can try using the same rig:

  • Move the CircleMask element off-center. The sweeping effect will still work.
  • Squish or stretch the CircleMask shape. Apply keyframes to the mask at several frames in the cycle to create changes in the circle (e.g. bouncing effect).
  • Add circular-shaped art in the revealed drawings.
  • Rotate the master peg.

If you’d like, you can even try building a different rig. One idea that I tried was to use circular segments without a clipping layer. What seemed like a simpler technique ended up looking less smooth due to the difficulty in splitting the circle perfectly in half to create the shutters.

I’ve got some other ideas to try with my sweeping circle rig. Stay tuned for a report out and hopefully a demo or showcase video. Feel free to share YOUR results with the rig.

I hope this helps you wonderful folks out there, especially Toon Boom Studio users who can build and play with this rig right away.

Happy Creating!


You must be logged in to post a comment.