These are heady days for the gay and lesbian community, with Supreme Court decisions and public-opinion polls reflecting startling shifts in views on issues such as gay marriage. Not surprisingly, the upcoming edition of the Outfest Los Angeles LGBT Film Festival projects these changing attitudes.

The festival, which begins Thursday and runs through July 21, comes just two weeks after the U.S. Supreme Court struck down the federal Defense of Marriage Act and cleared the way for same-sex marriages in California.

"I think films tend to reflect what is going on in society," noted KP Pepe, the festival's programming director. "Filmmakers and artists tend to be on the cutting edge of culture, so they are moving us forward."

For Outfest executive director Kirsten Schaffer, the decisions, along with polls showing a majority of Americans now favoring gay marriage, were a cause for celebration. But on the eve of the festival, she noted that the battles weren't over.

"We are thrilled with both outcomes and we acknowledge as a community there is still a lot more to be done in the states that don't have marriage equality," Schaffer said. "We will continue to rally, but it's a huge step forward."

Looking backward has its place as well. The theme of this year's festival is "Heroes," showcasing documentaries on such artists and activists as authors Alice Walker and Gore Vidal.

"We heard a lot in the news how the culture has changed faster than the law in a lot of places and in a lot of ways," said Schaffer. "I think that is because of cultural leaders like Gore Vidal and Alice Walker changing people."

Begun in 1982, Outfest is the longest-running continuous film festival in the city. This year's version features 157 films and videos from 28 countries in seven languages, with 85 public programs, seven galas, 61 features, 11 short films programs and 11 panels and special events.

"C.O.G.," based on a story by David Sedaris, stars Jonathan Groff from "Glee" as a closeted gay college student who gets more than he bargains for when he spends a summer picking apples in Oregon.

"It feels more like a coming-of-age story than a coming-out story," said Pepe. "The character is definitely dealing with coming of age and his sexuality but also issues of class and religion."

Alvarez was drawn to Sedaris' story because "it was about all the elements of the human condition," he said. "The elements were fueled by certain LGBT themes, but it was not about those themes."

He also liked how Sedaris deals with coming out.

"A coming-out story is usually presented as either you are in the closet or you are out of the closet," explained Alvarez. "I think for most people it is much more gray area, not necessarily a confusion about sexuality, but confusion about community.

"I think that is the thing that people underestimate a lot, which I find very interesting. When you come out of the closet and you start to identify as gay, you suddenly become part of a community. Sometimes you fit into that community and sometimes you don't."

"Pit Stop," highlighted as a festival "Centerpiece" selection, is set in a small Texas town and examines the aftermath of a husband coming out to his wife.

"I feel as storytellers, we gravitated toward the big dramatic points," said Tan, who developed his script at the Outfest Screenwriting Lab.

"I think that's why we have had a lot of gay films revolving around the big coming out moment," noted Tan. "But I think we have sort of moved beyond that. I am interested in finding what the consequences are after you come out."

In "G.B.F.," which also was developed at Outfest lab, the gay male best friend makes the leap from sidekick to lead role. Michael J. Willett plays a newly outed high school student who becomes the "gay best friend" of three of the school's popular girls

"I knew gay people would love it," said Stein. "But the script by George Northy had so much, it didn't read like a gay movie. It felt like a mainstream teen comedy about this phenomenon of the 'G.B.F.' that is happening with teen girls in high school at the moment. I think obviously we are skewering the notion of it, but it's still a way for a teen movie to feature a gay protagonist and have it be a story about tolerance."