President Obama participates in a "Civil Society Roundtable" with gay, lesbian, bisexual and transgender activists Sept. 6 in St. Petersburg. (Pablo Martinez Monsivais/AP)

Hoping to shine a light on Russia's new anti-gay law, President Obama met with civil rights activists during his final official function in St. Petersburg at the G-20 economic summit.

The president sat down with nine activists in a hotel meeting room, along with national security adviser Susan Rice and U.S. Ambassador to Russia Michael McFaul. In brief remarks before the meeting, Obama called their work "critically important" in creating an open society.

"I'm very proud of their work," the president said. "Part of good government is making sure we're creating a space for civil society."

Russia's law bans the distribution of materials to minors that suggest that  homosexual relationships are normal or attractive. That law was among a list of reasons that White House officials cited last month when they canceled Obama's scheduled bilateral meeting with Russian President Vladimir Putin in Moscow this week. The two leaders spoke briefly in St. Petersburg, but reporters noted tension between them.

Obama criticized the law in a news conference last month but said he does not think the U.S. should boycott the Winter Olympics in Sochi early next year.

“We’ve got a bunch of Americans out there who are training hard, who are doing everything they can to succeed,” Obama said last month. “Nobody’s more offended than me about some of the anti-gay and lesbian legislation that you’ve been seeing in Russia. But as I said just this week, I’ve spoken out about that, not just with respect to Russia but with a number of other countries, where we continue to do work with them but we have a strong disagreement on this issue.”