When the Oscar-winning screenwriter of American Beauty, Alan Ball, told his mother that he was gay, he was stunned when she told him that she believed his father had been as well.

It was a story that stayed with him for a long time, until it finally inspired his latest film, the coming of age tale Uncle Frank, about a teenage girl who leaves her hometown in the rural south of the US to study in New York, where her beloved uncle is a professor.

She soon learns Frank is gay, and living with his longtime partner in an arrangement that he has kept secret for years. But when her father dies, the pair travel back home to face his long-buried trauma.

"When I came out of the closet to my mother, she surprised me by saying 'Well I blame your father for this, because I think he was that way too'," 63-year-old Ball remembers.

"I don't know if that is true, he was already dead at the time so I was never able to talk to him about it. But then the next day we drove past a lake and she said 'That is where Sam Lassiter drowned' and I said 'I don't know who that is' and she said 'He was a real, real real, good friend of your daddy's'.

"And then later I found out that my father had accompanied Sam's body on a train back to their hometown of Asheville, North Carolina, and I just had this big 'what if' in the back of my mind for years and years and finally my inner Tennessee Williams took over and I just wrote it.

"It's a story, it's not true, it's not autobiographical, I made it up, but it was triggered by something that was told to me that made me ask the question."

Set in 1973, Sophia Lillis (the star of horror film It and its sequel) plays Beth Bledsoe, who escapes the claustrophobic clutches of her Southern family to find herself in the big city.

Paul Bettany plays her uncle, the revered literature professor, who has been secretly living with his longtime partner Walid (Peter Macdissi), known as Wally.

When the duo reluctantly return home for the funeral, Wally follows too.

"One of my favourite movies of all time is To Kill A Mockingbird," says Ball, who also created the TV shows Six Feet Under and True Blood, as he mulls over the decision to tell the story through the eyes of Beth.

"It's very different but it does have a similar dynamic in that it's seen through the eyes of a young girl and it's part of her coming of age. That definitely influenced me but it's just the way the movie came out, my process is very unconscious, I don't plan things out, I just sit down and see where it takes me."

Ball also directed the film, which proved a different experience to handing over his writing to another filmmaker.

"I know what the scenes are supposed to accomplish and I know exactly what beats need to be in there, but also it's such a collaborative venture and you always get surprised.

"Actors always surprise me by doing something different than what I had imagined, but better, so I love the collaboration of it. I've been very very fortunate in handing over my work to other people to direct, for example Sam Mendes in American Beauty, so I've had mostly good experiences of that as well."

The writer is also conscious of comparisons that can be made between Uncle Frank and American Beauty, and the way male characters in both films reckon with their sexuality and sense of masculinity.

"It's not a conscious throughline but it is something that is very meaningful to me," he says. "And it's representative of my own struggles in terms of being gay and living in a culture that wants to just completely define me by that and nothing else."

He pauses for a moment.

"But I did a movie called Towelhead a few years back and there was nothing gay in that!"

For Macdissi, who is Ball's long-term partner, it was surprising when the filmmaker wanted to cast him as Wally.

Macdissi has appeared in a number of Ball's projects, including Six Feet Under, True Blood and Towelhead, but this time the part came as a surprise.

"I just told him 'Are you sure I'm the right actor for this role?' because normally I get cast as tormented guys and edgy and intense guys.

"So I was really surprised, it was like 'Oh wow, that is cool, that is a change,' so I was very appreciative.

"I'm the outsider in the movie, if you want to call it that, the outsider who wants to vicariously live through his partner's life because he had left his life behind and that is one of the reasons he pushes Frank to reconcile with his family and wants to go back to South Carolina to meet his family.

"He wants to have a family of his own in America because the family he has back in Saudi Arabia is just not reachable on that level, so I thought that was deftly written and not exactly what I expecting."

That long drive back to South Carolina from New York provided the actors with lengthy stretches in vintage cars and the chance to really form a natural bond.

"The car scenes gave us an opportunity to get to know each other," the actor remembers, "So the flow was really natural between Sophia and me, we didn't have to work hard to get the scenes and that was a blessing."

"I loved it a lot at first," adds Lillis, "because they are great cars and vintage and fun to be in and you get to be together, and it actually feels like we are on a road trip.

"But at the same time they are extremely hot and it was really hot outside, with not the greatest air conditioning, so after a few hours it got hard."

Uncle Frank is released on Amazon Prime Video on November 25.