A CGI-constructed movie like DreamWorks’ “Madagascar” can take many months to put in final form, but as co-directors Eric Darnell and Tom McGrath explained during a recent Dallas interview, the production process actually starts years before any animation begins. In the case of this picture, about a group of New York zoo animals–including a lion, a zebra, a hippo, a giraffe and a flock of escape-minded penguins who nearly steal the show–that wind up in the wild, the seed could be traced back to a meeting between the two men when McGrath, who was previously a director on “The Ren & Stimpy Show,” was working on a project which would feature, as he put it, “penguins as The Beatles in ‘A Hard Day’s Night.’” That project was shelved, but Darnell said, “I think in a way that was [how] penguins ended up being in ‘Madagascar.’ It wasn’t because of this ‘Rockumentary’ specifically. It was just the fact that we both recognized the comedic potential of penguins. They’re just funny–they’re natural comedians, and to…do something that’s counter-intuitive, whether it’s making them a great rock band or making them, in this case, these World War II-style POWs, steely-eyed, it’s just not what you expect penguins to be.”

But the transformation of the penguins was just one part of constructing a preliminary version of a feature script and then shaping and reshaping it over a period of years before beginning the actual animation. Part of the process involved handing over the draft to artists who put together comic-book style “storyboards” that incorporated a good many of their own ideas. “A lot of the sight gags in the movie were never on the page at all,” McGrath said. “[The artists] go off and take things in a direction we’d never thought of.” Darnell added, “A huge percentage of that came from the [story] artists.” And McGrath continued, “[The process] is truly valuable in that sense–you can just redraw it, or re-record it, and try new things. See what’s working and what’s not.” Darnell summed up: “We haven’t animated a single frame of the film in that first two-and-a -half years. It’s all done with these comic-book style representations of the film that we put up on screen and work and rework.”

The fashioning of the final script also involved contributions from the voice talent. “We [got our first choices],” McGrath said–Ben Stiller as Alex the Lion, Chris Rock as Marty the Zebra, Jada Pickett Smith as Gloria the Hippo, and David Schwimmer as Melman the Giraffe. “We came up with these characters first–personality types–and then we pursued them. And it’s great to have someone like Jeffrey Katzenberg, who knows a lot of these people and can bring them in. When we developed our characters for this film, we certainly listed Ben and Chris and Jada and David even before we pursued them. Just to hear how they sounded together…we clipped actual pieces from different performances they had done to hear the music of the voices, and how it worked.” Darnell added that as they performed their lines, the stars added their own input. “We get not only the name on the marquee–which is great–but we get their incredible talent, we get their brains,” he said. “They help us find these characters and figure out who they are. So by the time we’re ready to animate, we’ve made our movie and remade our movie maybe fifteen times.” McGrath added, “We don’t actually animate at all until we get all the vocal performances done and cut together and timed.”

Another important element in the construction of the film was the music, and tracks added as temporary measures can lead to big changes. In “Madagascar” the biggest musical number is “I Like To Move It, Move It” by Reel 2 Reel, which a herd of lemurs headed by King Julien (Sacha Baron Cohen) who adopt the big-city transplants are singing on their arrival. “We couldn’t think of how to depict these lemurs in Madagascar,” McGrath said. “How should we personify wild animals? Rave party! All they want to do is dance. Then one of our assistant editors, Clare [de Chenu], put in this song that was one of the big hits from the eighties or early nineties–I missed the whole rave thing–and I was ready to yank it out when Sacha said, ‘I want to sing it!’ And it became a big part of that scene.” And the song returns over the closing credits, as the various characters reappear to perform little dances as the names roll by. “We told the animators, pick whatever character you want to have dance, and do a really funny dance to ‘Move It,’” McGrath added. “All the animators had a great time.”

Among the animals that come back for a final curtain-call are the penguins with whom Darnell and McGrath’s collaboration began. And they reminded the writer-directors of what, finally, “Madagascar” is all about. “[The penguins are] kind of like a mini-version of our theme, [which is that] everybody in this movie is either trying to stay somewhere or get somewhere,” Darnell said, to which McGrath added, “The grass is greener.” Darnell continued: “And it’s all about everybody defining themselves by where they are or where they want to be. And the theme of the film is, it’s not where you are in this world, it’s who you’re with that matters. And that’s what our leads all have to learn before the movie’s done. The real conflict for Alex is not overcoming some bad guy, it’s overcoming something inside of himself, looking into his own heart and recognizing what’s most important.”