Get breaking news alerts and special reports. The news and stories that matter, delivered weekday mornings.

BALTIMORE — Baltimore police officers responding to the sound of gunshots near an apartment building fatally shot a man who fired at them with an "AR-15-style" gun, authorities said early Friday.

No officers were wounded nor anyone else in the shooting Thursday night in a neighborhood on the city's west side, police spokesman T.J. Smith said. He added that it wasn't immediately clear why the man had begun shooting.

Four plainclothes officers riding in an unmarked car heard gunfire coming from the building about 9:30 p.m. Thursday, Smith said at the briefing. The officers drove toward the sound and when they arrived, they saw a man shooting an "AR-15-style" gun, according to Smith.

We will hold next briefing tomorrow afternoon. This is the gun recovered from the scene. Watch #Periscope for brief: pic.twitter.com/1mhGIXUJSw — Baltimore Police (@BaltimorePolice) July 15, 2016

The shooting comes a week after police shootings of two black men, one in Louisiana and the other in Minnesota, stoked outrage among many in the African-American community and protests around the country. Tensions also were heightened in the U.S. by last week's killing of five police officers in Dallas by a black gunman.

Smith said the man started firing toward the officers, and two returned fire, Smith said. The suspect was shot at least once and retreated to the apartment building, according to the spokesman. He didn't immediate identify the officers, the man or the races of those involved. He said two officers who fired their weapons were being placed on administrative duties as is routine in such shootings.

Let our news meet your inbox. The news and stories that matters, delivered weekday mornings. This site is protected by recaptcha

Officers, who Smith said initially thought there might have been more than one suspect involved, surrounded the building and searched the area.

He said authorities found the gun in a tree line just behind the apartment complex and the suspect inside on the second level with at least one bullet wound to his upper body. He held up a picture of what he said was the weapon during his briefing.

The man was taken to a hospital, where he was pronounced dead, Smith said.

LIVE on #Periscope: Baltimore Police briefing on Police involved shooting https://t.co/1hsg8mewK4 — Baltimore Police (@BaltimorePolice) July 15, 2016

He said police were seeking answers so early in their investigation Friday.

"We don't have a victim ... No one has come forward and said, 'Hey, I was being shot at,'" he said.

The idea that the man was trying to lure officers to the scene with the gunfire is a "theory" police are looking into, Smith added.

"Officers were drawn due to gunfire; were they specifically drawn there by him if they might have known they were in the area? We don't know the answer to that yet, but that's something that we're trying to figure out," Smith said.

RELATED: Family of AR-15 Inventor: He Didn’t Intend It for Civilians

While the officers were in plainclothes, they were also wearing outer vests that were marked "police" on the front and back, he said.

Smith said early Friday that officers would be spending hours working the crime scene and he expected more information to be released later in the afternoon.

"There are a number of shell casings from this AR-15-style weapon on scene," he said.

He also said police were asking anyone in the area around the time of the shootings to come forward and help investigators.