This is not a new problem. In the 1950s there were half a million Americans locked up in snake-pit state hospitals, and there was a skid row in every major city. The ACLU successfully pushed for deinstitutionalization and the hospitals had to release all those people who did not pose a danger to anyone else, and now mentally ill and addicted people are on the streets.
No one is sleeping on a piece of cardboard under a highway overpass unless they have burned down every bridge with every person they know who owns a couch. They are not out there just because the plant closed or there are is a housing shortage. If a person can't stay in a shelter because they can't follow the rules, or access the services meant for them because they don't want to have someone else telling them what to do, there is nothing that can be done for them. I scoff when I see people that claim to be veterans panhandling, since the budget for the VA is hundreds of billions of dollars and they have programs to deal with homeless veterans, but the veteran will have to voluntarily access them and report to a hospital.
No one should be locked up simply because we don't want to see them, but if they are not locked up they will continue to live they way they do now. They won't use the psychotropic medication that might make them functional because it isn't a fun drug. They won't sit through hours of group therapy because that isn't fun either. They won't stop using drugs and alcohol because they are addicted. Changing people is the hardest thing anyone can do, and when mental illness, booze, and drugs like meth, crack, and smack are in the mix it is just about impossible. Get used to the homeless, and also talk to them to get a real picture of the problem. They won't bite, but they might smell bad, and they will ask you for money.