Two men have been charged in the shooting death of an off-duty Texas deputy who was gunned down after leaving a grocery store Thursday night and a third male is being sought, authorities said Friday. 

Joshua Stewart, 23, and Fredarius Clark, 19, are both charged with capital murder in connection with the death of Harris County Sheriff's Deputy Darren Almendarez.

PENNSYLVANIA OFFICER, SUSPECTED KILLED, 2 OFFICERS WOUNDED IN GUNFIRE EXCHANGE

Harris County Deputy Darren Almendarez ispictured in a video highlighting auto theft.

Harris County Deputy Darren Almendarez pictured in a sheriff’s department video.  (Harris County Sheriff's Office )

The deputy had just come out of a Joe V's Smart Shop with his wife when he saw a Nissan Altima backed up to his truck and two males under the truck, the Harris County Sheriff's Office said. 

"Possibly a catalytic converter that was being stolen," Harris County Sheriff Ed Gonzalez said at a news conference Thursday night. "We're not sure. Those details are still being investigated. But, he intervened. He intervened to try to stop a crime."

Almendarez, 51, told his wife to go somewhere safe and he approached the suspect vehicle, which by then had three people inside, authorities said.

Harris County Sheriff's Office Deputy Darren Almendarez was shot and killed Thursday.

Harris County Sheriff's Office Deputy Darren Almendarez was shot and killed Thursday while leaving a grocery store with his wife, authorities said. Two men have been arrested and charged in his death and a third is being sought. (Harris County Sheriff's Office)

As he walked over, he was fired upon and struck multiple times. The deputy managed to return fire and shot at least two suspects, 

They then fled the parking lot. Almendarez was taken to a hospital where he later died. 

Stewart and Clark arrived at a hospital in the suspect vehicle a short time later with gunshot wounds, authorities said. A third male described as between 17 and 19 years of age is being sought by investigators for questioning. 

Almendarez, a 23-year veteran of the sheriff's office who was most recently assigned to the auto theft division, was remembered Thursday night as a "fighter." He was recently the focus of a sheriff's office spotlight video where he offered steps to avoid buying a stolen vehicle and other tips. 

Harris County Sheriff Ed Gonzalez news briefing on the death of Deputy Darren Almendarez.

Harris County Sheriff Ed Gonzalez holds a media briefing regarding the death of Deputy Darren Almendarez late Thursday night. (FOX 26)

CLICK HERE TO GET THE FOX NEWS APP

At the time of his death, he had purchased groceries and was planning to have a cookout to celebrate his sister's birthday Friday, Gonzalez said. 

Fox News' Julia Musto contributed to this report.