Antonio Banderas used his recent heart attack to fuel his performance in Pedro Almodóvar’s film “Pain and Glory.”

Banderas — who suffered a cardiac arrest two years ago — discussed how it fueled his performances and changed his priorities during a conversation with former co-star Eddie Murphy (“Dolemite Is My Name”) for “Variety Studio: Actors on Actors.”

“I suffered a heart attack. When that happens to you, when you see death so close, you make different choices,” Banderas said. “The order of priorities of things you thought were important are not important anymore. What is really important is your daughter, your family, your friends and your vocation. I wouldn’t even say my professional life, my vocation as an actor.”

Murphy responded, “Do you think when you’re facing adversity, that that comes out when you’re on screen? That some stuff is there that wouldn’t be there if you weren’t going through the adversity?”

Banderas said his persona influences how he creates art.

“Eddie, we create with what we have, with the experiences that we’ve had in our life, good or bad,” Banderas said. “And that’s what will relate to you as a human being, the tools that we have to use as actors. I don’t play the trumpet, or I paint, or I write books, I use myself.

Murphy admitted it’s scary for him to “touch real stuff.”

“I did a scene recently where my father died and in real life, my dad passed away,” Murphy recalled. “I thought about it when I was doing the scene, but then it was like, ‘Oh, I’m not touching that.’ I just pretended I was sad as opposed to letting it really come in me and thinking about using it. I felt like I would be naked. You’re completely and totally vulnerable to it.”

Variety’s “Actors on Actors” issue is in newsstands everywhere now. The Emmy-nominated companion series will air on PBS stations and the World Channel starting in January. Check back for more from Banderas, Murphy and the other best actors from this year’s film season.

Watch more from the interview below: