One of my goals for this film was to find a way to animate a string so that I could hand draw the initial animation and then apply it to a string and further tweak it in Maya. My further hope was to integrate my 12 drawings-per-second into Maya so that it would key the in-betweens and make a smooth 24 frame-per-second finished animation. Lastly, I wanted to do this in the most automated way possilble. Although there are many ways one could attempt this (including one way which I recommend exploring using the pointOnCurve command in MEL), the following method that I used involved making each drawing a NURBS curve and then making that curve an Ikspline for a joint chain. Lastly I could key a series of lattice clusters for a lattice that encompassed the string's geometry to each joint and key them individually (keying clusters resulted in much smoother movement than keying joints whose in-betweens in space are dependent on the joint chain and, subsequently, very shaky).

Before

After

1. I started by doing the initial hand-drawn animation in Adobe Photoshop. I made each layer of a single photoshop file the individual frames of animation. Photoshop let's you play these layers using the "Animation Window" and you can even apply a layer as a background for all your files while testing. These layers can then be exported as a sequence of Photoshop files by going to File/Scripts/Export Layers to Files (Image 1). Before going to step 2, make sure that the files are as clean as possible, any extra bits of lines will create extra vectors that will have to be cleaned up eventually anyway. For me, some of my scenes involved two lines, but for this I found it easier to separate each as it's own series of files and work with them separately. Lastly, if your file names are messy, use Sequence 911 or a similar file re-numbering application to clean them up.
2. Now you can convert your Photoshop images to vector graphics using Adobe Illustrator. You can open up a single file and save a set of actions that gives you results to your liking and then simply run those actions on a whole folder of Photoshop files. These actions can be like those I did, a "Select All", "Trace Object", "Live Paint", and then a "Save As". Run these actions by using the Batch command in the Actions window (Image 2). For me the Trace Object settings were the most important part to get right as it determined how closely the vector drawing would match your original and still be a single vector line without too much junk. I used the options that follow and used "Set Default" so that the Actions I ran would use these same parameters (Image 3).

Image 1

Image 2

Image 3

3. You are ready to bring your files into Maya. First off, make sure to start with a fresh Maya scene. We can export our line to a Maya scene as we get further in the process. Now we are going to use a series of MEL scripts that can automate the bulk of our entire process. The first one to run is "MEL_open_ai" which will import each file and all of the vectors as NURBS curves in the order of the file sequence. My scripts need a bit of customization as detailed by the documentation inside each. I will try to make them more user friendly as I work on my thesis. After running the script, you'll get a batch of curves all oriented along a single 2-D space and a lot of transform nodes (Image 4).

Image 4

4. The next script to run is "MEL_Group" which will take the curves from each transform node and group them. Each group will correctly house all of the curves that belong to one frame of animation (Image 5). After running this script, delete all of the transform nodes, they are now empty.

5. We run the "MEL_Key" script to make each individual group visible for two frames of animation in Maya (Image 6).

Image 5

Image 6

Image 7

6. Time to clean up the curves. You'll find that some curves exist which were just dirt from you original drawings. Scroll through the timeline to find and delete these. In addition, some curves became two. Use Edit Curves\Attach Curves to correct these (Image 7). If you need to correct any CVs, do that now, too. Once you're done cleaning up, run a Delete By Type\History to get rid of the old curve nodes. If you were doing loops in your animation, run "MEL_Duplicator_optional" ito duplicate those loops rather than cleaning up the same set of curves lots of times (make sure your duplicate defaults are set to "copy" and not "instance" before running this script).
7. Run "MEL_Renumber" and this will fix up all your curves so they are now numbered the same as their parent group (Image 8 and Image 9). After this, you can save this Maya file and import it to your Maya scene. Be careful that the Maya scene doesn't have stray groups named like the ones you're importing, though. Select all the groups and place them by moving them together in your scene.

Image 8

Image 9

8. If you like, you can add some 3-dimensionality to your curves. Do this by making a NURBS plane with not too many CVs and sculpt it to the way you want your curves to be manipulated (Image 10). We will project the curves onto this plane, so keep in mind the angle that you will be projecting from as you sculpt your plane. Also, if you want 3-D movement, key the plane's CVs. When you are ready, select the window that shows the perspective you want to project from and run MEL_Key_to_NURBS_and_Dup". This script will make new curves from the NURBS plane projection (Image 11). You can run the script again and again as you further modify the NURBS plane, but just keep in mind that each time you run it, there will be a score of curves that are all left on the NURBS plane, slowing MAYA down as you tweak the plane. Unless you need to see the affect of the plane's movement on your curves, delete or hide these curves ASAP and hide the NURBS plane when you're done.

Image 10

Image 11

Image 12

9. You can now smooth out your curves a little bit. Select them all and do Edit Curves\Rebuild Curve-Options. Set your Number of Spans appropriately. I wanted 100 CVs so keep in mind that you get 3 extra CVs, so I entered 97 (Image 12).

10. After all this manipulation, some of our curves will be facing the wrong direction. Run "MEL_Reverse_curve_dir" to set them right.

11. Group all your new curves and hide or delete the originals, we will no longer use them. Now we will create our string. Make a joint chain that goes straight up by snapping joints to a grid in an orthographic view with the same number of joints as curve CVs. If you want less joints, it's ok, but you'll have to make a script modification in the next step. Model your string and make it the same length as the joint chain. Ceate a 3xZx3 lattice where Z is the same as your number of joints. Re-scale the lattice so each T division hits the centers of each joint. Lastly, run "MEL_Create_lattice_clusters_for_spline" to make clusters for your lattice and orient them with the joints. Double check your joint and cluster orientation match after running this script. Your result should look like Image 13.

Image 13

12. Here's your last script to run, "MEL_script_spline_key". This one is kind of a monster and may require you to update the "size($string_curves)" and "$time" parameters to run it in chunks rather than against all your curves. In addition, this script re-sizes your joint chain for every frame to give the string the appropriate amount of stretch. If you made a different number of joints than 100, you will want to adjust the "$jointlen" parameter to account for this change. If everything worked fine, you should get results like Images 14 and 15 below. Note that it's ok that the joints wiggle outside of the string as you play the animation. This is expected and is why we keyed the clusters instead of the joints.

Image 14

Image 15

13. I have one additional script that may be useful. In many cases the keyframes from one curve to the other give you a spline with points (and hence clusters) that are rotated more than 180 degrees away from one another. The clusters basically flip because there is no way to keep them consistently oriented. This is fine for the keyframes but will result in rapidly rotating in-betweens. To fix this, run "MEL_fix_flips_for_spline". You can adjust the tolerance of the degree of the flip based on your animation (currently it is the "200" degrees or above written throughout the program). If you have large changes from one keyframe curve to the next, you may want to consider increasing that number.