CINCINNATI (AP) _ The art gallery director who is on trial for showing erotic photos by Robert Mapplethorpe testified in his own defense Wednesday that he never wavered in his commitment to display the works.

Dennis Barrie, on trial with the Contemporary Arts Center on obscenity charges, said he and the gallery's board had talked about the controversy an exhibit of the photos had triggered in Washington, D.C.

The government-supported showing of Mapplethorpe's photos was canceled last year in Washington amid a debate over federal funding of art. The National Endowment for the Arts now requires grant applicants to certify that the awards will not be used for work that might be considered obscene. Sen. Jesse Helms, R-N.C., pressed for the policy.

Barrie, however, said the board strongly supported going ahead with the exhibit.

''This was an exhibition of high quality. It had been seen in other cities and was by a well-known artist,'' Barrie testified under questioning by his lawyer, H. Louis Sirkin, in Hamilton County Municipal Court.

Seven photographs in the 175-photo exhibit are at the center of the trial. Five show graphic sex acts involving men, and two show children whose genitals are exposed.

Barrie said he was not asked to alter the exhibit in any way and would not have considered doing so.

Under cross-examination by Assistant City Prosecutor Frank Prouty, Barrie restated the gallery's commitment to display the photos.

''I thought we had every right and every reason to bring this exhibition to this city,'' he said.

Prouty showed Barrie Mapplethorpe's five photographs of explicit sex acts and asked Barrie to comment on them.

''He knew about light. He knew about shadow. ... As difficult as the subject matter may be, you see the ability of the man working through. He was brilliant with a camera,'' Barrie said.

Following Barrie's testimony, defense attorneys asked Judge David Albanese to dismiss the charges, saying the prosecution had never proved its case and that the defense had answered the U.S. Supreme Court's test of obscenity.

That test asks whether the dominant theme of the artwork appeals to prurient interest in sex, whether the work is patently offensive based on contemporary community standards, and whether the work lacks serious artistic or political value.

Albanese denied the defense motion and recessed the trial until Thursday, when a prosecution rebuttal witness was to be called.

Albanese scheduled closing arguments to follow the rebuttal, and told the jury to expect to get the case Thursday.

The gallery board's legal counsel, Stuart Schloss, testified earlier Wednesday that the board tried to get legal protection before the show. The board filed a lawsuit asking the court to rule whether the exhibit was obscene.

The case was never heard and was dismissed the day before the April 7 public opening of ''Robert Mapplethorpe: The Perfect Moment.''

On April 7, a Hamilton County grand jury viewed the exhibit and returned misdemeanor indictments charging the gallery and Barrie with pandering obscenity and using children in nudity-related material.

If convicted of both misdemeanor charges, Barrie could be sentenced to one year in jail and fined $2,000. The gallery could be fined $10,000 for conviction on both counts.

Prosecutors argued that they needed only to show that the photographs were displayed in public, leaving it to the jury to determine whether the photographs were obscene.

Schloss testified that gallery officials thought the artistic merit of the exhibit made it exempt from Ohio's obscenity laws.

''At no time did we consider it obscene,'' Schloss said. ''It was a serious artistic exhibit.''

Owen Findsen, an arts reviewer for The Cincinnati Enquirer, and Jerry Stein, arts critic for The Cincinnati Post, testified Tuesday and Wednesday that they thought the exhibit had artistic merit.

Defense witnesses have described the exhibit as a retrospective of the professional life of Mapplethorpe, who died of AIDS in March 1989 at age 42.

The exhibit drew more than 80,000 people before its seven-week engagement ended May 26.

It went on to Boston where it opened despite protests and 103,000 tickets have been sold. The Boston show closes this week.