The attack ended hours later when police used a robot carrying a bomb to kill the shooter, the Dallas police chief said.
The Thursday night killings, at the end of a protest over this week’s pair of fatal shootings of black men by police in Louisiana and Minnesota, fueled a national debate over excessive police force. The overnight attack raised fears that others would seek to retaliate against police.
Authorities said that the gunman fired at least some of the shots in the attack but have not ruled out that other shooters were involved.
A U.S. government source said the shooter was identified as Micah X. Johnson, a member of the U.S. Army Reserve.
A string of killings of black men by police in cities including Ferguson, Missouri, New York, Baltimore and Chicago have given rise to the Black Lives Matter movement against excessive police force. The killings have spurred almost two years of largely peaceful street protests.
Thursday’s shooting sent protesters running in panic while swarms of police found themselves under attack by what they believed to be multiple gunmen using high-powered rifles at ground level and on rooftops.
During lengthy negotiations with police, the gunman said “the end is coming,” according to Dallas Police Chief David Brown.
“He said he was upset about the recent police shootings,” said Brown, who is black. “The suspect said he was upset at white people. The suspect stated that he wanted to kill white people, especially white officers.”
Brown declined to say how many people took part in the attack. “We’re going to keep these suspects guessing,” he told reporters at City Hall.
Police said they were questioning two occupants of a Mercedes they had pulled over after seeing a man throwing a camouflage bag inside the back of the vehicle, which then sped off on a downtown street. A woman was also taken into custody near the garage where the standoff took place.
Reverend Jeff Hood, an organizer of Thursday night’s protest in Dallas, said he had been chatting with some of the police officers on the street when gunfire erupted.
“Immediately, when I heard the shots, I looked up and I saw what I believe were two police officers that went down. I didn’t know what to do,” Hood told reporters on Friday. “If we continue to turn to violence, we are going to continue to see heartache and devastation.”
A Twitter account describing itself as representing the Black Lives Matter movement sent the message: “Black Lives Matter advocates dignity, justice and freedom. Not murder.”
With Thursday’s attack, 26 police officers have been shot and killed in the United States so far this year, according to the National Law Enforcement Officers Memorial Fund. That is up 44 percent from the same period in 2015.
DEADLIEST DAY SINCE 9/11
It was the deadliest day for police in the United States since the Sept. 11, 2001 attacks on New York and Washington.
A video taken by a witness shows a man with a rifle crouching at ground level and charging at and then shooting another person who appeared to be wearing a uniform. That person then collapsed to the ground.
The authenticity of the video could not be confirmed.
A total of 12 police officers and two civilians were shot during the attack, officials said. Three of the officers who were shot were women.
One of the dead officers was identified as Brent Thompson, 43. He was the first officer killed in the line of duty since Dallas Area Rapid Transit formed a police department in 1989, DART said on its website. Thompson joined DART in 2009.
Dallas Mayor Mike Rawlings told CBS News the people in custody, including one woman, were “not being cooperative” with police investigators. He said the assailant who was dead was being fingerprinted and his identity checked with federal authorities.
There was no sign of international links to the attacks, U.S. officials said on Friday.
Experts on extremist groups said such attacks are not necessarily carried out by an organization and are often the work of individuals. Black groups have not been linked to any recent violent attacks in the United States, they said.
CALLS FOR CALM
U.S. Attorney General Loretta Lynch said the Justice Department would assist in the investigation into the shooting.
“Do not let this week precipitate a new normal in this country,” Lynch told reporters in Washington.
President Barack Obama, who was traveling in Poland, expressed his “deepest condolences” to Rawlings on behalf of the U.S. people.
“We are horrified over these events and we are united with the people and police department in Dallas,” he said.
Obama said the FBI was in contact with Dallas police and that the federal government would provide assistance.
“We still don’t know all of the facts. What we do know is that there has been a vicious, calculated and despicable attack on law enforcement,” he said.
A large swath of downtown Dallas was closed to traffic on Friday as police gathered evidence.
The shooting happened as otherwise largely peaceful protests unfolded around the United States after the police shooting of Philando Castile, a 32-year-old black man, on Wednesday during a traffic stop near St. Paul, Minnesota.
The day earlier, police in Baton Rouge, Louisiana, shot dead Sterling, 37, while responding to a call alleging he had threatened someone with a gun.
Over the last two years, there have been periodic and sometimes violent protests over the use of police force against African-Americans in cities from Ferguson, Missouri, to Baltimore and New York. Anger has intensified when the officers were acquitted in trials or not charged at all.
Dallas is a pioneer in training its police officers in de-escalation techniques, Rawlings told reporters, saying the department had the lowest number of police-involved shootings of any large U.S. city.
Presidential candidates Republican Donald Trump and Democrat Hillary Clinton canceled planned events following the attack.
LISA MARIA GARZA