Michael Douglas and Matt Damon used their own marriages as inspiration for 'Behind the Candelabra'.

The actors play gay lovers in the new Liberace biopic - which focuses on his secret relationship with Scott Thorson - and they felt they could ''relate'' to the couple because of their own marriages.

Speaking at the film's press conference at Cannes Film Festival, Damon said: ''What it felt like was a a love story, a movie about a real, long-term relationship.

''And I think that, for Michael and me, that was a way in. We're both married and we've both been in these relationships for a while and so we could relate.''

Douglas is married to actress Catherine Zeta-Jones, while Damon is wed to Luciana Barroso.

The Steven Soderbergh-directed flick is based on Thorson's tell-all book about his relationship with the famous pianist which ended acrimoniously.

Despite their long-term relationship, Thorson was left with nothing when Liberace ended the relationship as he was not recognised as a legal spouse, and Damon feels the film shines a spotlight on the current debate about legalisation of gay marriage in the United States.

He said: ''The guys around [Thorson] at the time referred to it as a marriage. Had it been a relationship between a man and a woman, it would have been a marriage, they could have parted and come to some arrangement.''