Director Sam Mendes looks down on the red carpet before attending the screening of his new film 'Away We Go' at the opening night of the Edinburgh International Film Festival, Scotland June 17, 2009. REUTERS/David Moir

Willy Wonka could soon be kicking up his heels.

Warner Bros. is developing a stage musical based on Charlie and the Chocolate Factory, the children's classic that it bought to the big screen four years ago.

The idea is to take the candy-colored set pieces -- seen most elaborately in the effects of Tim Burton's 2005 picture -- and translate them to the stage, while also transferring musical elements that animated the film along with new numbers.

Sam Mendes, an English theater veteran who went on to bring American Beauty and Revolutionary Road to the big screen, will produce the project with business partner Caro Newling. He is eyeing it as a directing vehicle, but is far from making a decision, said people familiar with the situation.

David Greig has been hired to write the book. The Scottish playwright has penned a slew of plays, including Damascus, The American Pilot and the real-estate drama The Architect, which became a 2006 movie starring Anthony LaPaglia.

Marc Shaiman and Scott Wittman, meanwhile, will compose the music; both worked on the big screen treatment of Hairspray.

Roald Dahl's children's classic -- about a poor boy who wins a tour of a mysterious chocolate factory from the eccentric Willy Wonka -- first came to the screen in 1971 from Paramount as Willy Wonka & the Chocolate Factory. The Warners version, titled Charlie and the Chocolate Factory and starring Johnny Depp as Wonka, made nearly $500 million worldwide for the studio in 2005, fusing Dahl's quirky imagination with Burton's elaborate visuals.

The property has been known for its music. The 1971 version won an Oscar for best original score and featured hits such as The Candy Man Can, while the 2005 picture featured a score composed (and a few songs sung) by Danny Elfman.

Mendes has been the rare presence who toggles between film and stage work. He came to prominence as artistic director at London's Donmar Warehouse, and on the British stage has directed the Stephen Sondheim musical Assassins as well as the revival of Cabaret, among others. In the U.S., he has in the past few years helmed Gypsy and The Vertical Hours on Broadway and Shakespeare and Chekhov at BAM.

He is currently contemplating a number of film projects, particularly at Focus Features, where he is developing the George Eliot novel Middlemarch, the cattle-herding saga Butcher's Crossing and the post-9/11 tale Netherland as producing and potential directing vehicles. He's also attached to the comic-book adaptation 'Preacher. Mendes most recently directed the young-parent dramedy Away We Go for Focus.