The video above is from ABC13's live-streaming channel.
Officials said a Cypress Fairbanks Independent School District officer noticed a crash in the 12500 block of Windern Road and went to investigate.
Cypress Fairbanks police said the officer tried to talk to the driver involved, but things took a turn.
The driver allegedly attacked the officer, and the officer responded with gunfire.
According to Cy-Fair ISD Police Chief Eric Mendez, a second car pulled up with the suspect's relative, who also joined in on the altercation.
Mendez said fortunately for his officer, a Harris County Sheriff's deputy was driving by and pulled over to assist.
Both officers were treated for minor injuries.
One of the suspects is in stable condition after being treated for serious injuries at the hospital. The other suspect is still at the hospital for treatment.
An investigation is underway at this time.
For updates on this story, follow Alex Bozarjian on Facebook, X and Instagram.