The film begins with the king’s death and Shrek’s sudden ascension to the throne. Becoming king is not only a shock to Shrek, it’s an uncomfortable role for the oafish ogre to play—and he’s soon sailing off with his friends Donkey and Puss In Boots to recruit a replacement. As the boat leaves the dock, Princess Fiona, Dragon, and a flurry of tiny Dronkeys (Dragon and Donkey’s children) wave good-bye. And then, at the last possible second, Fiona gives Shrek his second shock: She tells him she’s pregnant.
Into the void left by Shrek, Donkey, and Puss rides handsome Prince Charming, who persuades all the bad fairy-tale characters to join him in a palace coup d’etat. They capture the princesses and the queen, and throw them in the dungeon.
Meanwhile, Shrek has found Artie, the king’s replacement, in a high school. “He’s the ultimate outcast,” says director Chris Miller of Artie. “He’s below the guys wearing retainers who are playing Dungeons & Dragons.” At first, Artie finds the new power position exciting, but when he considers the weighty responsibility, he freaks out. He doesn’t feel worthy.
“In this movie, everyone has a preconceived notion of who they are and what they’re supposed to do in life,” says Miller. “Every character in the movie has been told by society or people close to them that they’re supposed to act one way. Every character breaks free of that notion.” Every character except the queen and Fiona, that is. “They’re the strong characters. People around them change.”
To bring these characters and the fairy-tale kingdom of Far Far Away to life, a team of 350 people at PDI/DreamWorks Animation worked on the film’s 1320 shots. You’d think that with two films about Shrek already under their belts, along with several other feature animations, PDI/DreamWorks would have run across any CG technique a story could demand. Not so.
For Shrek the Third, the studio encountered several “firsts.” Shrek appears in a costume for the first time in this film. It was the first time that animators dealt with characters wearing high heels, the first time a character had a flowing beard, and the first time characters ripped off pieces of their clothing. It was also the first time lighters worked under completely overcast skies.
With more characters in Shrek the Third than in previous films and more costumes—23 key characters and more than 4000 generic characters—the crew not only created techniques to meet the “firsts,” they also advanced their rigging, costuming, and hairstyling systems.
Tim Cheung led the animation team. “We divided the animators into four teams, each with a supervisor, and had two animators dedicated to crowd animation,” he says. “Before, animators worked on crowds in addition to their regular shots.”
With the exception of the crowds, each animation team handled all the characters in a sequence, and each sequence took between six to eight weeks to complete. Cheung worked on all the sequences. “I tend to animate more than some animation heads,” he says. “I oversee all of it, but in particular, I make sure that Shrek is consistent throughout.” About half the animators had not worked on either of the two earlier Shrek films.
Cheung began working with character technical director supervisors Larry Cutler and Lucia Modesto about a year and a half before animation began to define and implement new controls, refine the existing controls, and test the new characters: Artie and a wizard named Merlin. “And Shrek got an upgrade,” he says, “which was great.”
Modesto and Cutler began by collecting drawings and other reference materials from the art department, the storyboards from the story department, and the 3D models from the modeling department. Then, they organized methods to make it possible for the animators to position the models in any pose they wanted. For Shrek 2, the crew largely had reused the models and rigs for the legacy characters. That changed with Shrek the Third.
“We set up all the original characters—Shrek, Fiona, Donkey, and Dragon—from the ground up,” says Cutler. “The exteriors had to look the same, but they had new controls that gave them more range of motion.”
PDI had modeled and rigged the original characters in 1998, and much has changed in the nearly 10 years since. For example, modelers originally built Shrek’s shoes into his model; he didn’t have toes. “Our tools and techniques are different now,” Cutler says. “We wanted to give Shrek better shoulders and arms. We added a scapula and a more detailed anatomical structure. And, we put in an ‘auto shoulder.’ It added complexity to the setup, but when the animators move the upper arm, the shoulder moves with it. They don’t have to deal with animating the shoulder.”
In addition, when Shrek steps into the king’s shoes, he’s dressed to suit the role in a costume with a cinched waist, high heels, poofy pants, and a ruffled collar that covers his neck and rests on his wig. And as if that weren’t enough for the riggers to deal with, his costume flies off.
Modelers delivered the characters, which they had built in Autodesk’s Maya, with their arms outstretched, in a T pose. The character TDs then built the armature, which is the skeletal structure, and the articulation points, which are the joints. Controls added to the armature created the system that the animators used to move the characters, that is, the animation system.
“We have tons of controls on top of the armature,” says Cutler. In addition to the auto-shoulder, for example, the TDs built a foot pivot system that enables animators to get walking behavior using three controls, even when the characters wear high heels. “Normally, a foot rocks, lifts, and rocks down,” he explains. “With high heels, the heel is already raised and the toes are bent. But from the animator’s perspective, the controls are the same.”
Next, the TDs added muscles and fat using a proprietary system for deformation that represents muscles by building up layers. “It’s a simplified way of representing muscles,” says Modesto. The team didn’t use deformation, however, to cinch Shrek’s waist; they built an alternate body.
The faces changed the most. “As the skin slides over the bone, you can see the muscle changing volume and colliding,” says Modesto. “You can also see the bone structure underneath the eyebrows, and the Adam’s apple in the neck.”
Similarly, by using these muscle layers, the character TDs caused characters’ lips to fatten when pressed together, made the lower parts of eyes puffy, and gave Artie dimples.
Once the armature, joints, motion system, muscles, and fat were in place, the character TDs worked on hair and cloth systems.
The effects team simulated Merlin’s beard (above) by running a single joint chain down the center
(left, bottom), applying a low-res deformation cage (center), then attaching hair to the face surface (right).
“We threw out the simulation engine that we used for hair in Shrek 1 and 2,” says Cutler. “Now we have two engines: one for short hair and one for long hair. Merlin’s beard goes almost to the floor, so R&D wrote a simulation engine specifically for long hair and curly hair.”
In general, the hair systems use guide hairs driven off surfaces to control the overall head of hair’s shape and volume. “In Shrek 2, when Prince Charming tosses his hair, it was a one-off shot,” says Matt Baer, head of effects. “In [Shrek the Third], we not only have complicated hair that’s hard to style, but it’s in motion.”
To move Merlin’s beard, the crew developed a technique they named the “rigid rod.” “It responds to character motion,” Baer explains. “But we can add forces.” Rather than using long lines or curves, they created a chain so that the beard wouldn’t split apart. Then, to prevent the pieces of the chain from moving independently, they used deformation. “Rather than one line, we had a polygon cage so we could use deformation techniques,” says Cutler. “That gave us more control points that we could access. We’d simulate the beard, but we also had a second layer with finer grain control.”
The TDs used the same system for Rapunzel’s long braid and Guinevere’s locks of hair that bounce near her face. Most of the other key characters, however, used the simulation engine designed for short hair. Of those, one of the most difficult was Sleeping Beauty, who has shoulder-length, straight hair. The effects crew simulated her hair on a shot-by-shot basis. “We wanted her hair to stick a little bit when it brushes against her shoulder,” says Baer. “Friction is the hardest.” For the generic characters, the TDs used the magnet-based grooming system developed for Shrek 2 (see “After Effects,” May 2004).
The costumers created a loose-fi tting tunic for Artie, a gawky teenager,
which doesn’t help convince us that this outcast can become the new king of
Far Far Away, but Shrek is determined.
Many from Few
One of the big advances for Shrek the Third was that the crew created major characters using generic models and rigs. “We had fewer unique setups in this film than in Shrek 2, but we had more characters,” says Modesto. “In Shrek, we had Men A, B, and C, because we couldn’t get enough variety from the generics,” says Modesto. In Shrek 2, we had Men A and B, and Woman A and B. In Shrek the Third, we have Men A and B and Woman A.”
Captain Hook, a master of ceremonies, Mable the bartender, the princesses, the witches, Lancelot, a hairdresser, and others, as well as people in the crowds, are all variations created from three generics: Men A, a thin model; Men B, a fat model; and Woman A. From those, the character TDs created five variations each for Men A and Men B, and nine variations for Woman A. “We didn’t need to have two women because the director didn’t need a fatter woman than we could get with Woman A,” says Modesto.
To modify the generic geometry even further, character builders could make arms wider and bodies taller using the joint structure, and by using the deformation layer, change the volume of the characters to make them fatter or skinnier. Because the faces of these generic models have the same fat and cartilage layers as the models for the principal actors, the crew could fatten or depress cheeks, thicken lips, grow and shrink noses and chins, and morph skulls into new shapes. Captain Hook got a hooknose, for example; Lancelot got manly jowls.
A “casting tool” created by the character TD department allowed the layout and surfacing departments to give the generics a selection of clothes, shoes, and hairstyles. “The important thing is having a variety of silhouettes of the heads,” says Modesto. “So we get that with hats and hair. In Shrek 2, the top of the skull had to be the same for every character, but in Shrek the Third, you can add hairstyles and hats that keep the correct shape even though the cranium changes.”
To prevent fashion faux pas, the TDs built an early-warning system into the casting tool. “For example, if someone picks the wrong pants to go with a pair of shoes, they turn red,” says Modesto
. “The casting tool creates only valid variations.”
At left top, artists in the layout department block out camera moves and character poses.
At left bottom, animators work with more fully realized characters to create the performances.
Above, the fi nal image rendered with textures and lighting
In Shrek and Shrek 2, Fiona and the other female characters wore costumes designed so that, for the most part, only their skirts needed to move when they did. In Shrek the Third, some of the characters wear costumes that move from head to toe.
“Cloth was a big area of development,” says Baer. “We had layers of simulated cloth, characters that had worn spandex now had dynamic sleeves, and the characters acted with the cloth. That opened story possibilities.” Shrek’s tightly cinched costume pops open, for example. Even characters in crowds wore clothes that moved.
Character effects supervisor Bill Seneshen led the teams that worked with the apparel. To construct the costumes, the digital tailors built panels as if they were stitching together real clothes. Then, they placed the panels onto unmoving characters to check whether the clothes would wrinkle and fold correctly when the cloth relaxed.
For the cloth simulations, PDI/DreamWorks uses Maya cloth and sometimes Syflex. To help avoid unwanted collisions once the cloth starts moving—a skirt cutting through a leg, for example—they often used a second, featureless model of the characters. “The featureless figure acted as a collision body,” says Seneshen. “We could sculpt out areas on this figure to avoid collisions.”
During a scene in which the princesses decide to fight back after Prince Charming’s coup, Sleeping Beauty tears off the bottom of her skirt, and Show White rips off her sleeve. “The torn pieces are separate pieces of geometry,” says Seneshen. “We used texture maps and our fur shader to create tatters.”
To give women in the crowds skirts that flowed and the men tunics that moved, the character effects department devised a way to bake out simulations that they could apply to baked, looping walk cycles. “The system knows which simulation to use for a given cycle based on how many steps the character takes and how much distance it covers,” says Seneshen. “Our ‘mob team’ could tweak the rate of the stride.”
The character effects department’s team of 15 people also “finaled” the characters. “We’d retouch the geometry and underlying simulations, and do things like soft-tissue deformations,” says Seneshen. They might create a depression in a character’s cheek, for example, if the character comes into the department with his hand resting on his cheek. For this, they use sculpting tools in Maya and custom plug-ins.
The department also handled hair simulations, and animated all the props the characters interact with. “Anything that involves characters comes to us,” says Seneshen. “They’ll come to us if it involves cloth or strand simulation, if it wiggles, or if a character interacts with it.”
The effects department began work on Shrek the Third by coordinating with the layout department. Next, they created rough animatics for the effects shots. Included in those effects were such natural phenomena as fire, water, and plants.
For fire, the crew decided to use Maya’s fluid simulator. “We liked the test we ran, but the question was how would we art-direct the fire,” says Baer. “The fire looked nice out of the box, but we needed to bend the timings. In one shot, the Dronkeys set a bed on fire; in another, a princess burns her bra. In addition, Shrek’s boat catches fire, the Dragon and the little Dronkeys all breathe fire, and there are numerous torches in Far Far Away. “Usually, we’re told that effects humor is not funny,” says Baer, “but we got to create funny fire—that is, fire used in funny shots.”
To art-direct all these various types of fire, the effects technical directors developed new ways to emit density and temperature into the grid used by Maya’s fluid simulator. “We tweaked the emitter, not the simulator,” explains Baer.
For the ocean, the team leveraged technology from Madagascar
(see “Born to be Wild,” May 2005). When the water washes onto the beach, they art-directed each foam piece. “We created some with rough texture maps,” says Baer. “Some surfaces were like textured, stretching sprites that generated particles. Many of our tools are like little LEGOs. They start out as one-offs like Prince Charming’s hair in Shrek 2 or the foam pieces, and we propagate them into our tool set.”
Above, princesses prepare for battle. At right, top to bottom:
Cloth panels for Sleeping Beauty’s tear-away skirt, the stitched panels
unrelaxed and relaxed, the tear-away portion in green, and, at bottom, Beauty rips her skirt.
The key challenge for the forests was creating artistic shapes with controllable shadows. “We tried to be good neighbors to the lighters,” says Baer. “We’d give them a tree-wedging grid so they could work with just a few leaves before turning on all the leaves.”
The increases in compute power as well as the team’s experience has made formerly exotic lighting techniques commonplace. Subsurface scattering, once reserved for hero characters, now softens the skin on generic characters and even on many of the characters in the crowds.
On Shrek 2, the lighting team used global illumination (GI) on characters, but on Shrek the Third, environments received the sophisticated lighting, as well. “Once we have the global illumination set up, we can plug it in within shots,” says Philippe Gluckman, visual effects supervisor.
That became particularly important for a sequence that takes place in overcast lighting. “We had to rely on subtleties to bring form to the characters,” Gluckman says. “GI helps. We could sculpt where we wanted to use it. We can set key directions and get fills.”
To choose areas where GI would help, the lighting team simulated scenes in coarse resolution before running the calculations on the full-resolution geometry. Also, to speed the process, they often used baked GI. “We’d calculate the GI once and apply it to many scenes,” Gluckman says. “It worked as long as things didn’t move.”
New, efficient ways to create characters and effects such as these helped PDI/DreamWorks create a richer, more highly detailed film than the series’ predecessors. Could the third Shrek film be even more popular than the first two? The first Shrek won an Oscar and raked in $484 million at the worldwide box office. Shrek 2 was nominated for an Oscar and did nearly twice as well at the box office, generating $920 million worldwide. It still holds on to seventh place in the all-time biggest box-office race.
“The fun thing about working on Shrek is that everyone wants to do it,” says Raman Hui, co-director. If the enthusiasm of the crew is any indication, look for a charmed third time for the fractured fairy tale.
Barbara Robertson is an award-winning writer and a contributing editor for Computer Graphics World. She can be reached at BarbaraRR@comcast.net.