By Piya Sinha-Roy

TORONTO (Reuters) - When veteran filmmaker Oliver Stone was casting an actor to play former NSA contractor-turned-whistleblower Edward Snowden in a film, he said he went to only one person - Joseph Gordon-Levitt.

"I don't know why, he just looked like, and felt like, and acted like he was one of that generation, very much the same age and computer knowledgeable," Stone told Reuters last month in Los Angeles.

"Snowden," which had its world premiere on Friday at the Toronto International Film Festival and hits theaters on September 16, sees Gordon-Levitt, 35, play the 33-year-old Snowden through a decade of his life.

Gordon-Levitt, who achieved fame as a child actor in television series "3rd Rock from the Sun," said that by playing Snowden, he hoped to understand his motivations.

"I was kind of trying to figure out why he did what he did, what was going on in his head," he said. "And one of the questions everyone asks is, 'Why didn't he just, you know, voice his concerns through proper channels?'"

The film leads up to the events of 2013, when Snowden fled the United States after exposing the government's mass surveillance programs to journalist Glenn Greenwald and documentary filmmaker Laura Poitras.

The U.S. government filed espionage charges against Snowden and he was granted asylum in Russia, where he has lived since, with his girlfriend Lindsay Mills. Actress Shailene Woodley plays Mills in the film.

Gordon-Levitt said he related to Snowden's disillusionment with the U.S. government after watching U.S. National Intelligence director James Clapper deny, before a congressional committee, that the NSA was collecting records on millions of Americans.

"If the director of National Intelligence is being asked by a senator under oath, 'Hey, is this happening?' and he's telling a lie, well, then, what is some guy that works at the NSA going to accomplish by complaining through proper channels?" the actor said.

Tech-savvy Gordon-Levitt, who said he donated his fee for the film to the American Civil Liberties Union, is the founder of HitRecord, an online collaborative creative hub to brings together artists from around the world.

He said he tended to be optimistic about new technology but the movie made him more aware of its negative aspects.

"It's worth being optimistic about all those things, but it's also probably worth paying attention and considering what might the downsides be of this new technology that we're inheriting," he said.

(Reporting by Piya Sinha-Roy; Editing by Clarence Fernandez)