When you've written a hit novel that has taken on a life of its own and become a beloved modern classic, translating it to film might render a bit of nervousness -- particularly if you're taking on the task yourself.

Author Stephen Chbosky's "The Perks of Being a Wallflower," published in 1999 and one of the American Library Association's top 10 most frequently challenged books (it has been banned from its share of high schools), took on such a life over the last decade. But for the writer, it was less nervousness than a bit of anxiety and eagerness to actually see the film version through.

"I always wanted to do this one," Chbosky says. "This was the life-long dream, and everything I did, whether it was making my first movie or writing 'Rent' or doing 'Jericho,' it was always pointing to this moment. There was no way I was going to die without making this movie."

And naturally, he always had the film version in his head, to an extent. The novel is epistolary, so the visual storytelling isn't necessarily readily apparent, but Chbosky says he embraced the time away from it to be objective and to do a real adaptation in another medium. "I had to find the way to tap into the same emotion, the same characters, the same spirit and tone, but from a completely different point of view," he says. "And that was challenging, but it was incredibly rewarding to do."

What stuck out the most for him in translating his own work was the freedom and excitement of juxtaposition. It's something you can't really do in a book, or at least certainly not with any real ease. For example, there's a moment in the film when the taking of a communion wafer cuts to the dropping of a tab of LSD. That kind of thing was exciting for the author-as-screenwriter, as well as other editorial choices that, ultimately, serve to present memories and senses of place in the main character, Charlie's, mind, fully carving him out as a individual with depth. And that kind of thing is done with increasing confidence in the film, so much so that it's no wonder the film version of "Perks" was always simmering in Chbosky's mind.

Of course, other elements didn't present such obvious answers. "The more difficult and challenging thing," Chbosky says, "was trying to write Sam [played by Emma Watson] and Patrick [Ezra Miller] and Mary Elizabeth [Mae Whitman] in an objective way to make the audience fall in love with them the way that Charlie could simply say how much he loved them in the book. It’s really easy to have a character, a book, say, 'Oh, Patrick was so hilarious.' Well, when you actually have to write Patrick you better come up with some funny lines and cast the right person. And luckily with Ezra we did."

Indeed, Miller was a big fan of the novel and sought out the role, which he commands with assured ease in the film. Similarly, Logan Lerman is a revelation as Charlie. But Chbosky says he was never writing with actors in mind as he was adapting the story. It was only the novel he had in his head, the characters he had already created, and finding the best way to tell their story in a new medium. Nevertheless, the casting of the film is just right.

When Chbosky first met with Lerman, he was actually considering him for the part of Patrick. But the young star of films like "3:10 to Yuma" and TV's "Jack & Bobby" begged to audition for the lead. So he read two scenes to give an idea of range: a humorous, marijuana-induced rant and a much more sincere hospital scene later in the film.

"I always want to encourage the actor that if that’s what he was feeling passionate about, that’s what I wanted him to go for," Chbosky says. "He was the second person who auditioned for Charlie and after him there were no other auditions. There was no need; he was perfect. Within five seconds of his audition, what you saw in the movie, that was it. He had come up with this character. It got richer over time and he got more comfortable over time with the words and the place where we were shooting, but he had it. It was right."

Chbosky first really sparked to Watson after a moving scene with Daniel Radcliffe in "Harry Potter and the Half-Blood Prince." He knew she was serious about acting beyond that franchise and that moment proved it to him. "She was so beautiful and vulnerable and true to life in that moment, and I just thought that she had it," he says. "I met her in New York City and she’s such a nice person and legitimately generous, and I felt that she had a touch of being lonely, being in the eye of that hurricane. I just knew that she was the perfect misfit. I mean, she’s beautiful, but at the same time she always feels that she has something to prove to herself."

And it's that way throughout the ensemble for Chbosky. "It was the right cast," he says. "You know, it’s funny. Over the years, there were times that I was asking myself like, 'Why don’t I just do the movie already? What are you waiting for?' And once I had all those kids on set I knew that I was waiting for this group. If I had done it three years ago, they would have been too young. Three years from now, they would have been too old. It had to be that group, that summer. I’m so happy it was."

The setting was equally important when envisioning the film. There was no way the story of "Perks" was going to be filmed in anywhere other than Chbosky's native Pittsburgh. It's somewhat serendipitous that with recent productions like "The Dark Knight Rises" and "Out of the Furnace," the area of southwest Pennsylvania is seeing more and more production these days, but regardless, that had to be the place.

"When I was writing the book I was picturing the Hollywood Theatre when they were doing 'Rocky Horror,'" Chbosky recalls. "I was picturing my street when it was luminaria. I remembered the texture of what it felt like to go to Friday night football games in my hometown and so just from my own sense of authenticity and my own personal connection, I had to do it there."

But of course, the setting informs the story thematically as much as those personal touches of detail carve it out as a living, breathing environment. And that was as important to Chbosky in the adaptation process as it was in the writing of the novel.

"Pittsburgh is a tough city and so in making 'Perks,' to get the tone right, I knew that it could not be sentimental," he says. "Even when it talked about tough issues, there had to be humor. I did not want to make a treacly movie. I wanted to make a true-to-life, celebratory look at all aspects of being a young person, from the most exciting to the most difficult. Pittsburgh is a beautiful city and I’m proud to be one of its sons, but it’s not a sentimental place and Pittsburgh toughness helped us a great deal.

"I’ll never forget the first week of shooting -- John Malkovich is one of the producers -- we were at dinner and he took me aside and he said, 'You know, your script has real heart, so you don’t need sentiment. Direct this like a guy from Pittsburgh; always get the tough take.' I took that to heart and it really served us well."

And if everything in Chbosky's career was pointing to this moment, then it's fair to say everything he's picked up along the way served him here as well. He's worked with Spike Lee, Chris Columbus, Jon Turteltaub "and all the journeymen on 'Jericho,'" as he calls his collaborators on the TV series. He's observed a lot but, he says, until you get there, until someone says, "Hey, we're running out of time and we're losing the light," you don't really know how you're going to respond. And the experience has shed more light on what filmmaking is for him.

"All of that showed me that making movies is a lot more blue-collar than it is white-collar," he says. "It’s hours on set, in the trenches, doing the work, and once I understood that, once I observed that with all these terrific directors that I worked for and worked with, I don’t know, it wasn’t a magic trick anymore. It was just about the work. And once it was just about the work, it was really easy, because I can be shy at times and some of the more glamorous parts of making movies makes me a little nervous, but hard work doesn’t make me nervous. So I’m grateful to them that they showed me that."

"The Perks of Being a Wallflower" premieres at the Toronto Film Festival on September 8. It opens nationwide on September 21.