Out actor Jonathan Groff reveals in an upcoming picture book that Looking changed his life.

The HBO drama about three gay friends living in San Francisco ended earlier this year with a feature film after two seasons.

(Related: Jonathan Groff: Sex on Looking feels political, essential to storyline.)

Groff's character of Patrick came to the city in search of love and became involved with two men, barber Richie (played by Raul Castillo) and boss Kevin (Russell Tovey).

Groff said that the conflict between Kevin and Patrick was inspired by his own experience with a former boyfriend.

“This job has changed my life in so many ways,” Groff said. “I've never played a character that hit so close to the bone. It felt like an extension of myself taking place in the present. Trying to figure out what it means to be gay. Patrick and I are from the same generation of gay men so it has been so real for me. I had told [writer/producer Andrew Haigh] of a break up I had where the other guy wanted to be in an open relationship – so he wrote that situation for Patrick and Kevin.”

The upcoming picture book, simply titled Looking, is available for pre-order now.