The How I Met Your Mother star will soon star in the stage production of Hedwig and the Angry Inch, a musical about a transgender glam-rock singer.

"Hedwig is bringing up a lot of super insecure things within me," NPH admits in the latest issue of Out magazine. "I have never thought drag was intoxicating, I've never had a fun drunken Halloween in drag, never been in heels, really. I've lived my whole life being attracted by masculinity—it's why I like guys. I'm not a super effete person, and I have to turn into that, and in doing so it brings up a lot of homophobic insecurities within myself."

In addition to his Hedwig role, Harris had to film an intense sex scene with his Gone Girl costar Rosamund Pike for the upcoming film adaptation of the hit novel.

The openly gay actor explained, "We had to rehearse the sex scene with [director] David [Fincher], like every inch of it—‘Then you put your mouth on his dick here, and then this number of thrusts, and then you ejaculate.' It was weird because we're technically breaking down the sex scene. He wanted it to be almost robotic, that we know exactly where we are, position-wise, where everything goes. And yet, through all of that, the whole ‘I'm gay' element was never even thought about."

The mag also asked about Harris' relationship with female fans, to which he answered, "I've found that a lot of girls have no issue with me being gay. They still want to marry me. And I love that."

Your information may be shared with other NBCUniversal businesses and used to better tailor our services and advertising to you. For more details about how we use your information, see our Privacy Policy. If you are located outside of the U.S., your information may be transferred to, processed and used in the U.S.