A Texas high school teacher allegedly had thousands of child pornography images in his home, some he reportedly took at his school.

The man's wife is the principal of another high school in the same district. She confirmed the arrest in an email to the school community.

The Texas Department of Public Safety and the Montgomery County Precinct 3 Internet Crimes Against Children raided James Paul Stone's home on Monday as part of an undercover investigation related to the possession or promotion of child pornography on the dark web.

Stone is a teacher at Tompkins High School in the Katy Independent School District.

Investigators claim Stone admitted to producing images on school grounds and at beaches and swimming pools around the Katy area.

Stone was placed under arrest and transported to the Fort Bend County Jail. Stone was charged with ten counts of possession of child pornography.

Stone's wife is the principal at a different Katy-area high school. Melinda Stone sent an email to parents saying she was unaware of his child porn, KTRK-TV reported.

She sent a second email to school staff saying she was cutting ties with her husband.

"My family and I are deeply disappointed in his actions and thus we do not have any plans to be involved in James' criminal proceedings as he navigates the next steps,'" Stone wrote in the email obtained by the Daily Mail.

Katy ISD says the investigation is ongoing.

The Montgomery County Precinct 3 Criminal Investigations Division says it has reason to believe there are several victims. They are asking them to help in the investigation.