So even if "good" smart people with fair judgement go, they are turned away.
Lots of people want to be the 'change from within'. I'm one of them - I spent years as a defense contractor despite the fact that I hate the US military industrial complex.
But in the case of the police, it's prevented.
Also, yes, the police sometimes do very good and important things. But Chris Rock has a joke about this - there can't be good airline pilots and bad airline pilots, all pilots have to be good pilots or there won't be pilots at all. Trust (in anyone but especially authority) takes 10 years to make and 10 seconds to break. So coming in at 50:50 just isn't good enough
You don't need brilliant officers, need ones that are just not dumb, + don't have some power trip complex. This is true for many jobs.
I think the USA has a problem with the way police and guns are viewed. There's a sense of distrust in authority which is sometimes justified. But also breeds overly defensive and pretty bad officers.
The standards are low. The pay is low and everybody hates them. Who would want to be a police officer?
So the problem feeds itself, bad people become police officers. Good people look around and quit.