Damaging evidence given by Bill Cosby in an accuser's lawsuit, including admissions that he gave young women drugs and alcohol before sex, can be used at his sex assault trial, a judge has ruled.
The defence has insisted Cosby gave evidence only after being promised he would never be charged over his 2004 encounter with accuser Andrea Constand, but his lawyers at the time never had an immunity agreement or put anything in writing.
"This court concludes that there was neither an agreement nor a promise not to prosecute, only an exercise of prosecutorial discretion," Montgomery County Judge Steven O'Neill wrote in his ruling.
Cosby, 79, acknowledged in the 2006 deposition that he had a string of extramarital relationships. He called them consensual, but many of the women say they were drugged and molested.
Cosby, questioned about the 2004 encounter at his home with Ms Constand, described being on his couch and putting his hand down her trrousers.
"I don't hear her say anything. And I don't feel her say anything. And so I continue and I go into the area that is somewhere between permission and rejection. I am not stopped," he said in his evidence.
Prosecutors describe Ms Constand as being semi-conscious after Cosby gave her three unmarked blue pills for stress that night.
The release of the deposition last year prompted them to reopen her 2005 police complaint and arrest Cosby days before the statute of limitations expired. Judge O'Neill plans to try the case by June.
The ruling on the deposition is one of two key pretrial issues that will determine the scope of the evidence against Cosby.
The other question is how many other accusers will be allowed to give evidence in prosecutors' attempt to show a pattern of similar conduct. Prosecutors hope to call 13 other women who say they were assaulted by Cosby as far back as the 1960s.
Two days of arguments on that issue are set for next week.
At a pretrial hearing earlier this year, Judge O'Neill said that Cosby's decision to give evidence at the deposition could have been strategic.
The actor - known as America's Dad for his top-rated family sitcom The Cosby Show, which ran from 1984 to 1992 - could have invoked his Fifth Amendment right not to incriminate himself, but jurors would have heard of that decision if the case went to trial.
Cosby instead settled Ms Constand's lawsuit, for an undisclosed amount, after finishing four days of evidence about his extramarital affairs, his friendship with Ms Constand and other topics.
In another excerpt, Cosby described a phone call with Ms Constand's mother a year later, when he refused to say what the pills were.
"I'm not going to argue with somebody's mother who is accusing me of something," he said. "And I'm apologising because I'm thinking this is a dirty old man with a young girl. I apologised. I said to the mother it was digital penetration."
Cosby also described getting seven prescriptions for quaaludes in the 1970s, which he said he kept on hand to give to women he hoped to seduce, "the same as a person would say, 'Have a drink'".
Ms Constand met Cosby at Temple University when she managed the women's basketball team.
He was a prominent university trustee.
She went to police in 2005 to report that he had sexually assaulted her a year earlier after taking what Cosby described as a herbal product.
Ms Constand, then 30, was dating a woman at the time and had no romantic interest in the 66-year-old Cosby, her lawyer has said.
District attorney Kevin Steele called the ruling on the deposition an important development in the 12-year-old case.
"Allowing the jury to hear Mr Cosby's deposition testimony is another step forward in this case and will aid the jury in making its determination. It's important that we are able to present all of the evidence available," Mr Steele said.
Defence lawyer Brian McMonagle had no comment on the decision.
The defence will fight strenuously to block the evidence of the other women, arguing that their accounts are vague, decades old and impossible to defend.
Cosby's lawyers had hoped to question the women in person to assess their credibility and relevance, but Judge O'Neill rejected the idea.
Defence lawyers also say Cosby is legally blind and can no longer recognise his accusers or help them prepare for trial.
Ms Constand is now a massage therapist in her native Ontario. She signed off on the decision by prosecutors to reopen the case.