SAN FRANCISCO — The Proposition 8 trial had a bit of everything Wednesday, from an expert doubting President Barack Obama’s support for gay rights to new revelations about the depth of Mormon church involvement in the political campaign to enact California’s same-sex marriage ban.

The trial day also included testimony from a gay man who described being forced by his outraged parents to undergo “conversion therapy” at a Southern California research center in hopes he would abandon homosexuality as a teenager. The testimony was targeted at an argument from foes of gay marriage who maintain homosexuality is a choice, not an inherent biological characteristic.

“I knew I was gay, just like I knew I was short and half Hispanic,” said Ryan Kendall, a Denver man who told the courtroom the therapy left him suicidal.

The testimony came in the seventh day of the Proposition 8 trial unfolding here before Chief U.S. District Judge Vaughn Walker, who is considering a legal challenge to the 2008 voter-approved ban on the right of gay and lesbian couples to wed. Same-sex couples have sued to overturn the law, saying it violates the equal protection clause of the U.S. Constitution.

The focus of Wednesday’s proceedings was the expert testimony of Gary Segura, a political-science professor at Stanford University.

Segura was called to testify on what he considers the political vulnerabilities of gays and lesbians, meant to buttress the plaintiffs’ argument that they need greater legal protections under the Constitution.

Prop. 8 supporters insist gays and lesbians have gained major political traction, but the Stanford professor argued strongly that they have “no meaningful political power.”

Segura took aim at Obama, saying he was “not a reliable ally” for gays and lesbians, citing his refusal to back gay marriage or end the military’s “don’t ask, don’t tell” policy. When Proposition 8’s lawyer showed a video of a speech last fall in which the president vowed to fight for gay rights, Segura was unyielding.

“I think President Obama is perhaps the best illustration of an ally who can’t be counted on, an ally whose rhetoric far exceeds his actions,” he said.

As Segura testified, lawyers for same-sex couples also triggered sparks by introducing documents revealing the active involvement of churches in the Proposition 8 campaign. Among other things, one e-mail from a Roman Catholic official praised the collaboration with the Mormon church in getting Proposition 8 passed. Other documents discussed the Mormon church’s substantial role in the campaign.

Segura called such direct church involvement against one group “unprecedented.”

Kate Kendell, an attorney with the National Center for Lesbian Rights, said the campaign against Proposition 8 knew of Mormon church involvement, but added that the evidence was an extraordinary glimpse into its “formal” role.

Proposition 8 lawyers were clearly dismayed that Walker allowed the church material into the trial. The initiative’s counsel, Andrew Pugno, argued that the evidence should be excluded as internal campaign communications, and that the judge was flouting a recent federal appeals court ruling that found many of them privileged as private political speech.

Contact Howard Mintz at 408-286-0236.