Two gunmen were killed after opening fire on a security officer outside a contest to draw the Muslim prophet Muhammad.
The men drove up to the Curtis Culwell Center in Garland, Texas, as the event was scheduled to end and began shooting at the security officer. Garland police officers returned fire, killing the men.
The event inside was a contest hosted by the New York-based American Freedom Defense Initiative that would award $10,000 for the best cartoon depicting Muhammad.
A police spokesman said that authorities were searching the gunmen's vehicle for explosives, saying: "Because of the situation of what was going on today and the history of what we've been told has happened at other events like this, we are considering their car (is) possibly containing a bomb."
Drawings such at the ones featured at the Texas event are deemed insulting to many followers of Islam and have sparked violence around the world. According to mainstream Islamic tradition, any physical depiction of the Prophet Muhammad — even a respectful one — is considered blasphemous.
In January, 12 people were killed by gunmen in an attack against the Paris office of the satirical newspaper Charlie Hebdo, which had lampooned Islam and other religions and used depictions of Muhammad.
Another deadly shooting occurred the following month at a free speech event in Copenhagen featuring an artist who had caricatured the prophet.
The Southern Poverty Law Center, which tracks hate groups in the US, lists the American Defense Initiative as an extremist anti-Muslim group.
The Curtis Culwell Center, a school-district owned public events space, was evacuated after the shooting, as were some surrounding businesses. The evacuation was lifted several hours later.
Police helicopters circled overhead as bomb squads worked on the car. The bodies of the gunmen, who had not yet been identified, were not immediately taken from the scene because they were too close to the car. The spokesman said they would be removed once the car was cleared.
The wounded security officer, who was unarmed, was treated and released from a local hospital.
Additional security was in place for Sunday's event. The sponsoring group has said it paid $10,000 for off-duty police officers and other private security.
The event featured speeches by American Freedom Defense Initiative president Pamela Geller and Geert Wilders, a Dutch lawmaker known for his outspoken criticism of Islam. Wilders, who received several standing ovations from the crowd, left immediately after his speech.
After the shooting, authorities escorted about 75 contest attendees to another room in the conference center, where a woman held up an American flag, and the crowd sang "God Bless America".
The group was then taken to a separate location, where they were held for about two hours until being briefly questioned by FBI agents and released.
Johnny Roby of Oklahoma City, Oklahoma, who was attending the contest, told the Associated Press he was outside the building when he heard about 20 shots that appeared to be coming from the direction of a passing car.
He said he then heard two single shots. He said he heard officers yell that they had the car before he was sent inside the building.
Geller said that the shooting showed how "needed our event really was".
Geller's group is known for mounting a campaign against the building of an Islamic center blocks from the World Trade Center site and for buying advertising space in cities across the US criticising Islam.
When a Chicago-based nonprofit held a January fundraiser in Garland designed to help Muslims combat negative depictions of their faith, Geller spearheaded about 1,000 picketers at the event.
One chanted: "Go back to your own countries! We don't want you here!" Others held signs with messages such as, "Insult those who behead others," an apparent reference to recent beheadings by the militant group Islamic State.