"how do you show that you are not a protester and just a photographer to avoid police crowd control tactics?"
You don't, really.
On the one hand, the vast majority of protests are peaceful low-key sort of things where the police are just watching what's going on (if they're even there), or ensuring protests and counter-protests remain separate. They're basically not worried about you or what you're doing.
And on the other hand, if they've closed ranks, they're worried about everyone and they literally don't care if you're a protestor or "just a photographer." Press accreditation might get you through a police line, but even that's no guarantee; plenty of accredited journalists were caught up and detained in the G8/G20 protests in Toronto.
So, for the most part, being a photographer at the front line of a protest means you need to think in much the same way as a protestor at the front line:
Be aware of the overall situation. Are things getting hostile or escalating? Have the police blocked the route? Have they blocked all the routes (bad sign)? Are they demanding protestors move back? Is anyone provoking the situation?
It's usually safe. In fact, photographers will often be just as plentiful as protestors at the police line, as that's where the good pictures are. This was true even at the most violent protests during the Edinburgh G8 in 20062005. You are more likely to get caught up in other people's scuffles, but that's what being at the front entails (see above about "being aware").
If people are being arrested, the police do not discriminate. You're in the crowd, it's easier for them to detain you and sort it out later. This entails being prepared to be arrested:
- Talking your way out is generally fruitless. If you say "I'm just a photographer" and they don't immediately send you on your way, there's likely no point arguing further, so be ready to tough it out.
- Have a copy of any relevant photographer's/media rights information. Generally just helpful to indicate you're covering the event, not participating (if you have the urge to wave it around and quote it, see above)
- Have the number for a local civil liberties or legal aid organisation. Often these are published by the involved protest groups. Write it on your arm in marker pen.
- Know your rights and obligations when arrested. Consulting the aforementioned civil liberties organisations before you go is a good start.
- Take medication? Have enough on you for 24 hours, a copy of your prescription, and tell the arresting officer about it, as well as any processing officers. (This is likely the only information you should volunteer.)
If the tear gas (etc) is being deployed, and you're on the wrong side of the police lines, it's basically out of your hands. Do not panic, try to stay out of any clashes, and stay away from anyone throwing anything back at the police (or be aware of the risk you're taking to get that particular picture). Staying where you are is often a surprisingly good choice. Do not assume having a camera means you aren't a target, if anything, assume the opposite. See above about being arrested.
NB: this is based on my experience in Canada, Switzerland, and the UK. Probably decent advice for most western-style developed democracies, though variations certainly exist. Concrete local knowledge will always trump general advice.