Mark Ruffalo

In HBO's adaptation of Larry Kramer's "The Normal Heart," Mark Ruffalo plays gay activist Ned Weeks, who witnesses a mysterious disease that has begun to claim the lives of many in his gay community and seeks answers with a fervor that ultimately alienates him from his peers. (Mel Melcon / Los Angeles Times / March 5, 2014)

Mark Ruffalo, knowing his host liked sweets, showed up at playwright Larry Kramer's Manhattan home with pastries in tow — unaware that the then-77-year-old's health now restricted such pleasures.

It was spring of last year and the actor was set to begin production on the long-attempted film adaptation of Kramer's groundbreaking 1985 AIDS-political play, "The Normal Heart." Little did he know it, but Ruffalo's true audition was just beginning.

"Are you queer?" the playwright asked right off.

"No, I'm not queer."

"Have you read my book ["Faggots"]?'

"No."

"Well, you have to read it, otherwise you can't fully play this part."

Ruffalo, recounting the exchange recently during a spirited conversation at a Hollywood hotel, called it his moment of recognition. "He was testing me," the 46-year-old actor said with the sort of sheepish smile that hindsight affords. "And I remember just feeling a sense of fear in that moment."

The actor, who has played roles ranging from a brawny green superhero (the Hulk in "The Avengers") to a hapless sperm donor to a lesbian couple ("The Kids Are All Right") in the course of his 25-year-career, now takes on Kramer's quasi-autobiographical Ned Weeks, the ornery gay activist at the center of "The Normal Heart" who fervently tries to shake the public to action after a mysterious disease begins plaguing the gay community in the early '80s. Even his friends at times find him beyond obnoxious.

After enduring a winding road from stage to screen, the story, which was significantly reworked, ultimately came to be marshaled and directed by Ryan Murphy and landed at HBO. It premieres May 25.

Imbued with passion, pain and fury, the drama beckons one to look back just as gay rights are undergoing a sea change. To remember — for some, imagine — a society before gay TV characters were a commonality and same-sex marriage an actuality in more and more places.

The action in "The Normal Heart" takes place between 1981 and 1984 in New York City, when the gay community was still in the reverberations of the Stonewall riots and the sexual revolution. It hones in on sexual politics during the early days of the AIDS crisis — with its central character undergoing moments of rage and powerlessness in the fight to raise awareness while most of his co-workers counseled a more moderate, step-by-step approach.

The film, which also stars Julia Roberts, Matt Bomer and Taylor Kitsch, comes on the heels of last year's critically acclaimed "Dallas Buyers Club" and the 2012 documentary "How to Survive a Plague," both of which tackled the early years of the AIDS crisis. That it finally has an air date is its own victory.

"It was one of those projects that was almost mythical in its inability to get made over the course of 30 years," Murphy said. Film adaptations have been "in the works" for years — most notably, Barbra Streisand, who owned the rights for 10 years, was going to helm it. The delay hasn't softened its significance, Murphy said.

"Prejudice killed millions and millions of people during that time," Murphy, the openly gay TV producer behind TV's "Glee" and "American Horror Story, said by phone. "That prejudice still exists today on some level. In hindsight, the thing that's different, at least for me, is when I was growing up, it felt very much like my life. And now it feels like my history. I can have the happy ending — the right to marry, the right to have a child. I owe a lot of my life and freedom to those who fought the fight back then. We all do."

'The inhumane response'

It's a period Ruffalo had lived through on the opposite coast, in Los Angeles, reading about the unexplained virus in the pages of the LA Weekly as a teenager. "It felt like a pandemic. And I was young, so I was still idealistic, and it was jarring to see the inhumane response to it all," he recalled. "It didn't compute. But Larry was right, I didn't fully understand how deep it went."

That's not to say Ruffalo is unfamiliar with unbridled zeal for a cause. Today a resident of upstate New York, the actor has cultivated a profile as an outspoken anti-fracking advocate — hosting rallies and speaking out on various cable news programs. "I knew what activism looked like inside and out," he said, pointing to the ACT UP (AIDS Coalition to Unleash Power) movement, a grassroots AIDS initiative co-founded by Kramer, as a model.

The pair's initial sit-down lasted three hours. From there, a friendship started. And the tutelage followed. The legendary — and divisive — figure in the gay rights movement offered a master class of sorts, sharing photos and stories of the places and people at the heart of the turmoil. He even offered Ruffalo his round-framed glasses for use in the film.

Kramer, who is HIV-positive and has undergone health complications since receiving a liver transplant more than a decade ago, retains his sense of humor. In an email, Kramer said he was struck with disbelief when Murphy put Ruffalo's name forward for the role of Ned.