It's an interesting one.
I think there can be good indoor systems as much as there can be bad outdoor systems - bad husbandry is bad husbandry. Does that make sense?
I agree with YL on this. I'm not sure that living belly deep in mud is pleasant or healthy for the pig or the keeper, although the initial post is about pig welfare rather than keeper welfare so I think there are probably good and bad examples of both.
When I was at University in the early 80s, the farms on the Bush Estate were developing high welfare ways of keeping pigs, based of the study of the behaviour of ourdoor pigs, that could operate successfully commercially. This included loose housing sows, later weaning of piglets, letting gilts being retained for breeding form family groups with their mothers.
I think it must be pretty hard to balance the highest welfare with making a living, and let's face it, if folk can't make a living, the prospect for pigs generally is poor.
On the dairy cows, I was on a few dairy farms in my year with RHET. Many of the high yielding cows were in 24/7 because concentrate feed was the only way to get enough nutrients into them to stop them miling themselves to death. But this is the way they have been bred and tbh, I didn't think they looked terribly stressed but again, I suspect there is good and bad husbandry in all management systems.
Our weaners have always been kept outside - but we only have two or three, and only for 6 months of the year in summer. If we had them over winter, I think I'd be looking at some form of housing.