James McAvoy chews the scenery and vomits it back in your face in this helter-skelter adaptation of Irvine Welsh’s novel. He plays Scottish copper Bruce Robertson, a racist, sexist and mostly pissed Machiavellian who wheels about Edinburgh creating havoc with his carefully-plotted schemes and silver tongue.

Robertson’s a deeply repellent and compelling piece of work. He’s all bent outta shape alright and when a chance of promotion comes up in his corrupt corner of the city, he will stop at nothing to clinch it.

It’s cocaine and chips for tea every night as he snorts and swigs his way to the top, setting his colleagues at each other’s throats, bedding their wives, and manipulating his idiot superiors.

Man, is it nasty but this being a Welsh novel, it is also very funny. Robertson’s boss, Chief Inspector Toal, is a wannabe screenwriter who hangs Kubrick posters on his wall, there are bitter and very funny pieces to camera worthy of Renton, a surreal cameo from David Soul, and Shirley Henderson (so good in Intermission) is hilarious as a glamour puss wife straight out of a bad seventies sitcom.

What tends to slow down the fun are Robertson’s hallucinatory sessions with his shrink (Jim Broadbent). The psychodrama is laid on too thickly with apparitions straight out of The Naked Lunch but your skin will prickle as Robertson’s sanity ebbs away.

McAvoy, all flinty stare and soulful eyes, is mesmerising and Edinburgh itself takes on a dark satanic chill in this pitch black tale of bent coppers, addiction and self-revulsion but it loses momentum as it lurches from one demonic episode to the next. Filth really wallows in the bad stuff but ends up taking an early shower.

Alan Corr