However, my grandfather worked for a while at such a sanitarium as you mention, and yes, the patients there did get more sunlight than they otherwise would have.
You are right. It's a mycobacterium.
If I posted "virus" above, I was sloppy in my posting. I should have done better, since I took isoniazid 3X a day for a year, my Senior year in high school, and had to get chest X-rays every three months for several years.
Boy...those were some clunky old x-ray "machines" back then.