An active shooter who opened fire on a federal courthouse in Dallas, Texas, is dead after meeting immediate armed resistance from law enforcement officials on Monday.

Video from the scene, obtained by the Dallas Morning News, shows an armed man shooting toward the entrance of the Earle Cabell Federal Building. However, armed law enforcement appears to immediately return fire as the attacker approaches the door to the building. After apparently being struck by shots from law enforcement, the attacker then flees across the street and collapses in a parking lot.

The attacker, identified by the FBI as a 22-year-old man from Fort Worth, was pronounced dead at the scene. No one else was injured in the ordeal.

A striking picture of the attacker captured by Morning News photographer Tom Fox in the moments before he opened fire show him holding a rifle and ammunition magazine while walking toward the entrance of the building. He is also wearing a mask, some sort of vest, and a magazine carrier around his waist.

Fox also captured video of the attack and its immediate aftermath as he hid behind a column while the violence unfolded. The video records some of the shots being fired and then the desperate search for the attacker. It then cuts to law enforcement officials rendering medical aid to the attacker as he lays in the parking lot.

Officials credited quick action by law enforcement for ending the incident with only the attacker being hurt.

"Shortly after the incident began this morning, officers from the federal protective service engaged the shooter," FBI special agent in charge Matthew DeSarno said in a press conference. "But for the actions of the federal protective service officers, this likely would have been a very deadly incident."

Erin Nealy Cox, U.S. attorney for the Northern District of Texas, labeled the officers who stopped the attacker heroes.

"I also want to thank, in particular, the federal protective service whose officers saved who knows how many people this morning by responding to the active shooter situation by neutralizing the shooter," Cox said during the same press conference. "These guys are our heroes today. We owe them a debt of gratitude."