Watch: Jake Gyllenhaal dishes on filming sex scenes with Jennifer Aniston
The 40-year-old Brokeback Mountain actor appeared opposite the 52-year-old Friends star in indie movie The Good Girl in 2004, about a depressed housewife who has a love affair with a younger colleague at the supermarket where she works.
Gyllenhaal - who has previously admitted he had a crush on Aniston - told The Howard Stern Show: "Oh yeah, it was torture, yes it was. But it was also not torture. I mean, come on, it was like a mix of both.
"Weirdly, love scenes are awkward, because there are maybe 30, 50 people watching it? That doesn't turn me on. It's oddly mechanical. And also it's a dance, you're choreographing for a camera. You can get in it but it's like a fight scene, you have to choreograph those scenes.
"The pillow technique was used. That was just pre-emptive and used generally always when actually in a horizontal place in that movie."
He added: "I think that was actually a Jennifer suggestion, she was very kind to suggest it before we began. She was like, 'I'm putting a pillow here.'"
Gyllenhaal admitted to People in 2016 that he had a crush on the Friends star when they worked together.
He said: "I will say, I had a crush on her for years. And working with her was not easy. I was – um, yeah. That's all I'm going to say. It was lovely. It wasn't hard, that's what I would say."
Asked if he had been a big fan of her as Rachel Geller in Friends he said: "Not so much Friends, but kind of her personality from afar, and movies she was in. And some of Friends – I'm not a huge Friends fan – but who she is."
Gyllenhaal is currently in a relationship with 25-year-old French model Jeanne Cadieu.
The Donnie Darko star told Stern he is keen to start a family.
He said: "That's all I want - is to be a good husband and a father, that really is what I want.
"Now that I have fulfilled a lot of things in my career that I feel comfortable with, I can safely say that. I don't know if I could have said that before."