OXNARD (CBSLA) – A suspect carrying a replica handgun was tracked down and captured by Oxnard police with the help of a drone earlier this week, the first time ever Oxnard police have used a drone in such an arrest.

An image taken by a drone shows a suspect hiding in the backyard of a home in Oxnard, Calif., on Nov. 12, 2019. (Oxnard Police Department)

Alex Perez was apprehended on charges of brandishing a weapon and being under the influence of a controlled substance, Oxnard police reported Thursday.

READ MORE: LA County To Expand Access To Coronavirus Vaccine To More Essential Workers Starting Monday

Late Tuesday night, Oxnard police officers responding to a report of a man brandishing a gun in the 1900 block of North Ventura Road arrived to catch sight of the suspect running through the neighborhood.

Thermal imaging from the drone. (Oxnard PD)

They established a perimeter and deployed a drone equipped with a thermal camera, police said. The camera helped officers locate the suspect hiding in a backyard in the 1300 block of Kingswood Drive.

READ MORE: Meet The Giltinis: LA's New Rugby Team to Open Play At Coliseum March 20

Perez eventually surrendered to police and a replica handgun which he had discarded was seized.

The Federal Aviation Administration recently gave the department permission to utilize drones, and this was the first time one was used, police said.

MORE NEWS: High Winds Expected To Continue Through Sunday For Parts Of SoCal

“We are very pleased that our first drone deployment was able to assist our officers in taking a potentially dangerous suspect into custody,” Assistant Chief Jason Benites said. “Last night’s deployment is a great example of how this quickly-evolving technology can be used to make our communities safer.”