BATON ROUGE, La. — Three law enforcement officers were fatally shot and three others wounded Sunday in Baton Rouge, less than two weeks after the killing of a black man here by police sparked nightly protests that reverberated across the nation.
The gunman, a former Marine who was identified as Gavin Long, 29, of Kansas City, Mo., was killed by the police who responded to a report of a man carrying an assault rifle, authorities said. The shootings took place in a section of the city where people have been rallying in opposition to police tactics.
Police said initially that they were looking for other suspects, but the superintendent of the Louisiana State Police, Colonel Michael Edmonson, said at a news conference the gunman who attacked the officers had been shot and killed at the scene.
“There is not an active shooter scenario in Baton Rouge,” Edmonson said. Two persons were detained for questioning in the nearby town of Addis.
State and local officials did not address whether the police were targeted specifically or whether they were shot trying to intervene during a crime. However, they acknowledged the tensions in the country this month surrounding the killings of black men by police officers, and the retaliatory violence directed at law enforcement.
Sunday’s shooting was the fourth high-profile deadly encounter in the United States involving police over the past two weeks, leaving 12 people dead, including eight police officers.
The latest Baton Rouge shooting took place after city officers on July 5 fatally shot Alton B. Sterling, a black man who was selling CDs outside a convenience store.
The night after Sterling was killed, a black man was killed by the police during a traffic stop in a St. Paul, Minn., suburb, and then the next night, five police officers were killed by a gunman in Dallas who said he particularly wanted to kill white officers.
Edmonson said a call came in to the Baton Rouge police dispatch early Sunday reporting “a guy carrying a weapon” near the Hammond Aire Plaza shopping center on Airline Highway.
At about 8:40 a.m., law enforcement officers observed the man, wearing all black and holding a rifle, outside a beauty supply store, he said. Within the next 4 minutes, there were reports of shots fired and officers struck, said Edmonson, whose agency will take the lead on the investigation assisted by local and federal investigators.
All told, six officers were shot, he said. Three of them died — two from the Baton Rouge Police Department and one from the sheriff’s office — one sheriff’s deputy remained in critical condition, and the remaining two were in stable condition, he said.
State Representative Ted James identified one of the three officers killed Sunday as Montrell Jackson and said he had a 4-month-old child, the Associated Press reported.
The father of another officer slain, Matthew Gerald, confirmed that his son was killed in Baton Rouge, according to The Washington Post.
A spokeswoman for the East Baton Rouge Parish Sheriff’s Office has identified the third officer killed during a shooting in Baton Rouge as sheriff’s deputy Brad Garafola.
Law enforcement officers converged on Long’s house in Kansas City searching for evidence, the Associated Press said. Some officers had weapons drawn from behind trees. Others took cover behind cars.
Long was a Marine who served a year in Iraq, according to his service record. He joined the corps in 2005, served five years and was made a sergeant in 2008. A University of Alabama spokesman said Long attended the school for one semester in the spring of 2012.
Mark Clements, who lives near the shopping center, said he was in his backyard when he heard shots ring out. “I heard probably 10 to 12 gunshots go off,” he said in a telephone interview. “We heard a bunch of sirens and choppers and everything since then.”
Avery Hall, 17, a worker at a nearby car wash, said he was on his way to work when the gunfire erupted. “I was about to pull in at about 8:45 and we got caught in the crossfire,” he said.
“I heard a lot of gunshots — a lot,’’ Hall said. “I saw police ducking and shooting. I stopped and pulled into the Dodge dealership. I got out and heard more gunshots. We ducked.”
On the police department’s dispatch radio, a voice could be heard shouting: “Shots fired! Officer down! Shots fired. Officer down! Got a city officer down.”
At about 8:48 a.m., officers fired at the suspect, killing him, Edmonson said.
Asked if investigators believed the police had been targeted, Kip Holden, the mayor-president of East Baton Rouge Parish, noted that the police were responding to a report of a man with a weapon.
“Based upon that, it would not seem that they were targeted,” Holden said. “They responded to a call that said there’s this guy walking along the street in these dark clothes, carrying a rifle.” Louisiana is an open-carry state.
Violence against law enforcement, Governor John Bel Edwards of Louisiana said, “doesn’t address any injustice, perceived or real. It is just an injustice in and of itself.”
Baton Rouge Police Chief Carl Dabadie Jr. called the shooting “senseless” and asked people to pray for the officers and their families.
He said the department would continue to work to protect the citizens. “We are going to get through this as a family,” he said, “and we’re going to get through this together.”
Just five days after traveling to a memorial service in Dallas for the five police officers killed there, President Obama addressed the new killings of police officers Sunday. In remarks from the White House, he said the killings were “an attack on all of us.”
“We have our divisions, and they are not new,” he said, noting that the country was likely in store for some heated language during the 2016 Republican National Convention in Cleveland this week.
‘‘That is why it is so important that everyone — right now — focus on words and actions that can unite this country rather than divide it further,’’ he said. “We need to temper our words and open our hearts, all of us.”
Police in Baton Rouge had in recent days announced that they were investigating a plot by four people to shoot at police officers, and they cited the threat to explain the heavy police presence at protests.
Police said a 17-year-old was arrested after running from a burglary July 9 of the Cash American Pawn Shop in Baton Rouge. He and three others, including a 12-year-old arrested Friday, were believed to have broken into the pawn shop through the roof. It was unclear whether the burglary was in any way connected to Sunday’s shooting.
Dabadie told reporters at the time that the 17-year-old had told police “that the reason the burglary was being done was to harm police officers.”
The explanation, however, was met with skepticism on social media sites, where many people believed the report was concocted by the police to justify their militarized response to the protest.
The intense protests after Sterling’s shooting were beginning to lose steam. Sima Atri, a social justice lawyer who represented some of the protesters arrested last weekend, said earlier in the week that many protesters were too afraid to hit the streets after the authorities’ heavy-handed approach last weekend, which included nearly 200 arrests. Nearly 100 charges were dropped Friday.
A protest on Saturday afternoon had less than a dozen people — all of them white — huddled on the side of the road under a tent to escape the blazing sun, flashing signs at passing cars. Once the sun went down, the crowd grew to about 125, most of them white, Arthur Reed, of the group Stop the Killing, said.
Corporal L’Jean McKneely of the Baton Rouge police said it was unclear if the shooting was connected to the protests.